|
| |
|
|
carrie
Posts: 251 From: Port Orange, FL Volusia Status: offline
|
Can divs submit forms? - 8/19/2008 16:28:51
Hi all, I've got code like this: <div class="linkblock"> <form method="POST" action="searchres.asp" name="propsearch"> <input type="hidden" name="listings" value="Our_Listings" > <input type="hidden" name="sectype" value="Single Family Detached" > <input type="hidden" name="Proptype" value="Homes" > <input type="image" src="../images/listings/home.jpg"> </form> <div class="linkblockheader"> Homes</div> <div style="clear:left;"></div> </div> Where a user would click on the image and submit a form. The linkblock div is actually a bit wider than just the image, and I'd like for the whole 'linkblock' div to be clickable (and change backgrounds on hover while I'm at it), which I can do in .css, by enclosing the div inside a hyperlink, and setting the various styles, but what I can't do, is make the whole div clickable and then still submit the form. Is there a way to do what I describe without using javascript to submit the form? Can you make entire forms clickable? Thanks, Carrie
|
|
|
|
Tailslide
Posts: 6265 Joined: 5/10/2005 From: Out here on the raggedy edge Status: offline
|
RE: Can divs submit forms? - 8/20/2008 2:44:07
Not sure why you'd want it to... Is the form just basically searching for all houses (for instance)? If so, why have the form there? Why not just have the clickable div linking to a page that displays all the houses?
_____________________________
"My strategy is so simple an idiot could have devised it" Little Blue Plane Web Design | Blood, Sweat & Rust - A Land Rover restoration project
|
|
|
|
carrie
Posts: 251 From: Port Orange, FL Volusia Status: offline
|
RE: Can divs submit forms? - 8/20/2008 8:49:04
Thanks Tailslide, This form submits 3 or 4 form fields to the following page. It displays all homes for the brokerage (as opposed to all homes for the entire county), so there are a few fields I need to pass, and I just prefer not to send them in the URL. Looks like I'll have to find a workaround, huh? Maybe on the 'homes' page, the code could retrieve the referring URL, and if it matches the page this div is on, then I could set the value of the fields that way, and just eliminate the need for forms altogether. Carrie
|
|
New Messages |
No New Messages |
Hot Topic w/ New Messages |
Hot Topic w/o New Messages |
Locked w/ New Messages |
Locked w/o New Messages |
|
Post New Thread
Reply to Message
Post New Poll
Submit Vote
Delete My Own Post
Delete My Own Thread
Rate Posts
|
|
|