Forum Moderators: open
I have a list of 13 dates in a mysql db stored as varchar like this
Jan 3 - Mar 19
The dates get used by numerous products, each date has 2 possible prices so on the prices page to add prices I call ALL dates in a while loop and end up with 3 (input type = text) boxes so I can type in the prices like so
[Jan 03 - Mar 19][pricea][priceb]
[Feb 07 - Mar 09][pricea][priceb]
[Apr 05 - Jun 16][pricea][priceb]
etc
etc
At the moment I am using print_r( $_POST ); to see what's coming through on submit but am not getting the first text box? heres what I get
[pricea1] => 100
[priceb1] => 110
[pricea2] => 110
[priceb2] => 120
No dates? I am using a counter increment each row of data
while ($newArray = mysql_fetch_array($result)){
$date = $newArray['date'];
print "<input type=\"text\" name=\"date$number\" value=\"$date\" disabled><input type=\"text\" name=\"pricea$number\"><input type=\"text\" name=\"priceb$number\"><br>";
$number = $number +1;
}
What is the best way to take this data and add it to a mysql database?