Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8511919
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T04:08:23+00:00 2026-06-11T04:08:23+00:00

I have a text field <form method=post> <input type=text name=number> <input type=submit value=submit name=ok>

  • 0

I have a text field

<form method="post">
<input type="text" name="number">
<input type="submit" value="submit" name="ok">
</form>

I want to enter a integer in this text field and want to open other text field(s) equal to number enter in that text field.

eg. I enter 4 number in the $number then the 4 text fields will open.

the code I used for this.

<?php
if(isset($_POST['ok']))
{
  extract($_POST);
  for($i=1;$i<=$number;i++)
  {
     <input type="text" name="">
     //insert mysql query to insert into table
  }
}
?>

but i don’t know how to insert these values in the table.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-11T04:08:24+00:00Added an answer on June 11, 2026 at 4:08 am

    Try like this

    <?php
    if(isset($_POST['ok']))
    {
       extract($_POST);
       for($i=1;$i<=$number;i++)
       {
          <input type="text" name="text[]">
         //insert mysql query to insert into table
       }
       //Here you insert the text field values with name "text" which is an array.You can implode them with ',' and insert into your database
     }
    ?>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

If have a html form like <form method=POST action=http://.../file.php> <input type=text name=data id=data />
I have a form with two text_fields: <input type=text id=post_name name=post[name] /> <input type=text
I have a form with two input text fields: <input id=ModelName_test_0 name=ModelName[test][0] type=text> <input
I have a method, -(void)validateFormInput:(UITextField *)textField that gets called when the form's submit button
I have a form in a PHP script and one text field. However when
In my TEdit field I have text in the form <number1>..<number2> . My idea
I have one form with several text fields and one button. When i enter
I have the following HTML form: <div id=main> <form Id=search-form action=/ViewRecord/AllRecord method=post> <div> <fieldset>
I have a text input which has a default value password. When the user
I have an <input type = text> binded with a keypress event, as follows

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.