Thread: Div Link
View Single Post
Old 08-22-2006, 11:51 AM   #2 (permalink)
sde
Moderator
 
sde's Avatar
 
Join Date: May 2002
Location: us.ca
Posts: 4,505
sde is on a distinguished road
well a form is not an attribute of a div, so i will guess your div should exist inside a form.

you can create an onclick event in your div and do what you want. since divs are not form fields, i created a hidden div and made the onclick event set the value of the hidden div before it submits the form.

HTML Code:
<form name="myform" method="POST" action="somescript.php">
<input type="hidden" id="myhiddenfield">

<div onclick="document.getElementById('myhiddenfield').value='452153'; document.forms['myform'].submit();"></div>
</form>
it's my best guess to what you are trying to do.
__________________
Mike
sde is offline   Reply With Quote