Wallpapers Forums Login

How To Submit A Form Without A Submit Button

today i was wondering how you can make a web form without using a submit button.

normally this is what i use for my web forms:

<input type="submit" name="submit" value"Submit">

but how about if instead of having a button, i can have a link? well, if you are wondering how you can do it, you can do it using javascript. you can use this code as an example:

HTML CODE:
<form name="myform" action="">
Search: <input type='text' name='query'>
<A href="javascript: submitform()">Search</A>
</form>
<SCRIPT language="JavaScript">
function submitform()
{
document.myform.submit();
}
</SCRIPT>
Search: Search
ralph Sun Jan 25, 2009
25-7024-ralph.gif
oh wow, that is amazing, great tutorial just what i was looking for. i am also a javascript geek. thanks man

Related Content

Information

Share

wallpaperama | Wallpapers | Forums | Terms Of Service

copyright © 2013 wallpaperama - All Rights Reserved - Last Updated Mon May 06, 2013 (-8 GMT)
Powered by: Webune Forums V5