Assigning variable to hidden form element
Posted: Sun Apr 23, 2006 5:36 am
Hi,
I have a page
http://www.something.com/imageupload?var=13
This takes you to a page with an upload form which has a hidden element. I have used the following code to set the hidden element's value;
When the form is posted to uploadprocess.php I then use the following to display the var value;
However nothing is displayed. I know my upload form hidden element code is wrong, but not sure how to fix this.
Please help.
I have a page
http://www.something.com/imageupload?var=13
This takes you to a page with an upload form which has a hidden element. I have used the following code to set the hidden element's value;
Code: Select all
<input name="var" type="hidden" id="var" value="<? $_GET['var']; ?>">Code: Select all
echo $_POST['var'];However nothing is displayed. I know my upload form hidden element code is wrong, but not sure how to fix this.
Please help.