I'm using html, php and mysql. I am using a php "while loop" to pull all the data out of a table
while($stuff = mysql_fetch_row($view))
and then display it in a table on a website.
<td colspan="2"> <? echo ($stuff[1]); ?>
ect.
One of the columns is a short description. I have a button under it that when clicked opens a new page which needs to pull the long description column out of the same table and displays it on the page. I also have an ID column. How do I pass the value of the ID column to the new page so I can do a query.
$HTTP_POST_VARS help
Moderator: General Moderators
store the ID to a hidden HTML field:
On your onClick() event of the button send the ID via the $_POST or $_GET
Code: Select all
<input type="e;hidden"e; name="e;thisID"e; value="e;<?php echo $myID;?>"e;>