Form Button

liunx

Guest
Instead of using the standard form buttons for submit/ reset etc, I have designed my own, but I am unsure what to do with the function to activate the button,<br />
<br />
ie where it normally says this:<br />
<br />
input type="submit" name="Submit" value="Submit"<br />
<br />
what do you have instead in the OnClick=?? function<br />
<br />
thanks!<!--content-->here is a snip of code that I have used for images instead of grey buttons. As you can see, I wrapped the image in a <href> tag and assigned an onClick event.<br />
<br />
<td><input type="image" src=http://www.htmlforums.com/archive/index.php/"submit.gif" width="75" height="35" border="0" alt="Submit" onClick="submit();"></td><br />
<br />
<br />
<br />
<td><a href=http://www.htmlforums.com/archive/index.php/"javascript: void(null)" alt="Reset" onClick="javascript: reset(); return true;"><img src="reset.gif" width=75 height=35 border=0 alt="Reset"></a></td><!--content-->If you use:<br />
<br />
<INPUT TYPE=IMAGE SRC=http://www.htmlforums.com/archive/index.php/button.gif NAME=whatever><br />
<br />
this will automatically be the same as:<br />
<br />
<INPUT TYPE=SUBMIT VALUE=Submit NAME=whatever><br />
<br />
there is no default image based reset button but you can use the clever method that Doc Web posted above to make an image function the same as a reset button.<br />
<br />
Regads,<!--content-->
 
Back
Top