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 8048613
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 5, 20262026-06-05T06:29:54+00:00 2026-06-05T06:29:54+00:00

I have a table form like this: <table class=table table-striped table-bordered table-condensed> <tbody> <tr><td><input

  • 0

I have a table form like this:

<table class="table table-striped table-bordered table-condensed">
            <tbody>
                <tr><td><input type="text" class="input-small" name="article" /></td>
                    <td>
                        <select name="colore">
                            <option value="nabuk">Nabuk</option>
                            <option value="nero">Nero</option>
                            <option value="blu">Blu</option>
                            <option value="rosso">Rosso</option>
                        </select>
                     </td>
                    <td>
                        <select name="fondo">
                            <option value="gomma">Gomma</option>
                            <option value="cuoio">Cuoio</option>
                            <option value="legno">Legno</option>
                        </select>
                    </td>
                    <td>
                        <select name="numero">
                            <option value="36">36</option>
                            <option value="37">37</option>
                            <option value="38">38</option>
                            <option value="39">39</option>
                        </select></td>
                    <td><input type="number" class="input-mini" min="1" max="200" name="qnt" step="1" /></td>
                    <td></td>
                </tr>
            </tbody>
        </table>

The user can add many rows to this table with a Jquery script. This script is OK and work properly.
After that, the table form is submitted through an Ajax post call to a PHP page with the $('form').serialize(); function of Jquery.

The problem is: how can I retrieve the values of each field of rows to the server side (PHP), without using hidden supplementary field (for example that submits the number of row in the table) or without use a progressive index for the name of the rows fields?

I haven’t found something that explains the solution… 😐

the next step of this script is passing the values of the table to the PHP with JSON object… but it’s a secondary problem 🙂

  • 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-05T06:29:55+00:00Added an answer on June 5, 2026 at 6:29 am

    You can use an array. Name your fields with [] at the end of them. For example,

    <select name="colore[]">
    ...
    <select name="fondo[]">
    ...
    <select name="numero[]">
    

    PHP will automatically update the indices as

    $_POST['colore'][0]
    $_POST['colore'][1]
    $_POST['colore'][2]
    etc.
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have this form:- <form action=> <table border=0> <td colspan=2 class=instruction>Select your desired option
Well i have a complex form view model like this : public class TransactionFormViewModel
I have a form that looks like this: <form id=addClassesToDoc action=> <table id=classesTable style=border-collapse:
I have Login.php form like this: class Form_Login extends Zend_Form { public function init()
I have a model like this: class Tour(models.Model): Name=models.CharField(max_length=100) Count=models.SmallIntegerField() ActionDate=models.DateTimeField(editable=False) ActionUser=models.ForeignKey(User,editable=False) StatusType=models.ForeignKey(StatusType) now
I have a submit buttom like this: <?php echo <form id='abottom' method='post'> <button name='.$row3[$ww].'
I have a Tabular type Form based upon a SELECT * FROM table type
I have this login form. This form is a grouped table view where the
I have a class that generates some html (form elements and table elements), but
I have a ViewModel. something like this public class ViewModel { public int Id

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.