I am printing a table that shows an outline of a daily meal plan that uses a for loop to repeat the same table 7 times for each day of the week. On each table I have put a button so that the user can move to another page to get a more detailed daily outline using
<FORM ACTION=dailyview.php METHOD=get><INPUT TYPE=submit NAME=Day VALUE=$counter></FORM>
This passes a number which can be added onto todays date which works fine but the problem is that it shows the number on the label of the button.
How can I pass the variable during the loop? I have been told to use a session variable but it overwrites with the new value as each table is printed.