Menu
In this sample I am using PHP to create 8 text boxes, the user types in info then submits form, but when I pull the data entered using the code below I am only getting the data typed into the last text box. The below example may not have a logical use, but I just simplified the script to try to understand why it is not working.
[code=php]<?php
$box = array(1, 2, 3, 4, 5, 6, 7, 8);
foreach($box as $boxes) {
echo'<li class=”box”><input name=”mytable[$boxes]” type=”text “size=”12″/></li>’;
}
?>
Display Page
[code=php]<?php
$textboxes = $_POST[“mytable”];
foreach($textboxes as $txt)
{
echo $txt;
}
?>
Thanks