How to transfer multiple rows output to another php file to process data?
<pre><code>&lt;form name="myForm" action="doControlAcc.php"  method="post" onsubmit="return validateForm(this);"&gt;
        &lt;table cellpadding="0" cellspacing="0" border="20" class="display" id="acc" width="200"&gt;
            &lt;thead&gt;
            &lt;tr&gt;&lt;h2&gt;Accessories summary&lt;/h2&gt;&lt;/tr&gt;
            &lt;tr&gt;
                &lt;th&gt;Type&lt;/th&gt;
                &lt;th&gt;Currently - Ex Factory&lt;/th&gt;
                &lt;th&gt;Minimum Required Stock&lt;/th&gt;
                &lt;th&gt;Update by&lt;/th&gt;
                &lt;th&gt;Last update&lt;/th&gt;
                &lt;th&gt;Re-Stock Amount&lt;/th&gt;
                &lt;th&gt;Stock Out&lt;/th&gt;

            &lt;/tr&gt;
            &lt;/thead&gt;
            &lt;tbody&gt;
               &lt;?php
               $accessories = array()
               $query  = "SELECT description, current_stock, min_required_stock, c_ex_factory, last_update from Accessories”;

                $result= mysqli_query($link, $query) or die(mysqli_error($link));      
                $row = mysqli_fetch_array($result);

                while($row = mysqli_fetch_array($result)){ 
                    $order = $row['c_ex_factory'] - $row['min_required_stock'];
                    if ($order &lt; 0){
                        $order = $row['min_required_stock']-$row['c_ex_factory'];
                        $color = "#FF0000";
                    }else{
                        $order = 0;
                        $color = "#00FF00";
                    }



                ?&gt;
            &lt;tr&gt;
                &lt;td name="accessories[]" id="accessories"   value=”&lt;?php echo $row['description'] ?&gt;” &lt;?php echo in_array($row['description', $ accessories) &gt; &lt;?php echo $row['description']; ?&gt; &lt;/td&gt;
                &lt;td align="center" name="accessories[]"  id="accessories"   value=”&lt;?php echo $row[''c_ex_factory '] ?&gt;” &lt;?php echo in_array($row[''c_ex_factory ', $ accessories) &gt; &lt;?php echo $row['c_ex_factory']; ?&gt; &lt;/td&gt;
                &lt;td align="center" name="accessories[]"  id="accessories"   value=”&lt;?php echo $row[''min_required_stock '] ?&gt;” &lt;?php echo in_array($row[''min_required_stock ', $ accessories) &gt; &lt;?php echo $row['min_required_stock']; ?&gt; &lt;/td&gt;
                &lt;td align="center" name="accessories[]"  id="accessories"   value=”&lt;?php echo $row[' name '] ?&gt;” &lt;?php echo in_array($row[' name ', $ accessories) &gt; &lt;?php echo $row['name']; ?&gt; &lt;/td&gt;
                &lt;td align="center" name="accessories[]"id="accessories"   value=”&lt;?php echo $row['description'] ?&gt;” &lt;?php echo in_array($row['description', $ accessories) &gt; &lt;?php echo $row['up_when']; ?&gt; &lt;/td&gt;
                &lt;td align="center" name="accessories[]"  bgcolor="&lt;?php echo $color; ?&gt;" id="accessories" &lt;?php echo in_array($row[' re_stock ', $ accessories) &gt; &lt;input type="text" size="5" name="re_stock" value=" &lt;?php echo $order ?&gt;"/&gt; &lt;/td&gt;
                &lt;td align="center" name="accessories[]"id="accessories"   &lt;?php echo in_array($row[' out_stock ', $ accessories) &gt; &lt;input type="text" size="5" name="out_stock" value ="0"/&gt;&lt;/td&gt;                    
            &lt;/tr&gt;

                &lt;?php

                }

                ?&gt;

               &lt;tr&gt;
                   &lt;td&gt; &lt;/td&gt; 
                   &lt;td&gt;                         &lt;/td&gt; 
                   &lt;td&gt;&lt;/td&gt; &lt;td&gt;&lt;/td&gt; &lt;td&gt;&lt;/td&gt; 
                &lt;td&gt;&lt;button  data-theme="b" id="submit" type="submit"&gt;Send order&lt;/button&gt;&lt;/td&gt;
            &lt;/tr&gt;
            &lt;/tbody&gt;

        &lt;/table&gt;

    &lt;/form&gt;
</code></pre>

<p>Hello,
I'm new to web programming.
The code above will fetch the data from database to create a table in PHP, then it will take the user inputs for stock-out and restock and send those to doControlAcc.php file. 
The problem I'm facing is I need to create multiple input lines so that users can enter stock-out and re-stock for different products. And I don't know how to pass these multiple lines to doControlAcc.php file after the form is filled. (i.e how can I access accessories array in doControlAcc.php?). </p>

<p>THank you for your help.</p>
