I have a form in a php page into which I would like to automatically add a URL paramenter into a field. The address would look something like:
http://www.websiteaddress/admin/add_data.php?file_name=image.jpg
The page add_data.php contains the following form (I've removed some colums for brevity). All I want to achieve is that the parameter file_name is the data entered into the cell containing:
<input type="text" name="image" id="image" value="<?php echo $row_getShip['image']; ?>" maxlength="150" />
So that when clicking 'insert' the name of the image file is already filled in in the correct box
Please help!
<form id="form1" name="form1" method="POST" action="<?php echo $editFormAction; ?>">
<p> </p>
<table width="1312" border="0">
<tr>
<td><input type="text" name="image" id="image" value="<?php echo $row_getShip['image']; ?>" maxlength="150" /></td>
<td><div align="right">
<input name="hiddenField" type="hidden" id="hiddenField" value="<?php echo $row_getShip['ship_id']; ?>" />
<input type="hidden" name="MM_update" value="form1" />
<input type="submit" name="insert" id="insert" value="Update" />
</div></td>
</tr>
</table>
</form>