Click to See Complete Forum and Search --> : Form Post Method without the Send button
amitabh
Nov 30th, 2001, 01:21 PM
Is there any to send data through POST method if I do not use the Submit button. I need to use image in place of the Send button.
crptcblade
Nov 30th, 2001, 02:06 PM
<form name="frmTest" method="POST" action="path/to/whatever.cgi">
<input type="text" name="txtTest" value="Hello"/>
<input type="image" src="image1.gif"/>
</form>
the image input becomes the submit button.
:)
CiberTHuG
Nov 30th, 2001, 02:10 PM
I would've just...
<div onclick="document.myForm.submit;"><img></div>
'Course, the div may be optional. You might be able to just put the onclick event on the img tag. And I really would put the submit in a function and call the function, but you get the idea.
crptcblade
Nov 30th, 2001, 02:13 PM
Just out of curiousity...
why go through all of that if there is a simple, one-line way to do it built in?
:)
amitabh
Dec 1st, 2001, 12:09 AM
Originally posted by crptcblade
<form name="frmTest" method="POST" action="path/to/whatever.cgi">
<input type="text" name="txtTest" value="Hello"/>
<input type="image" src="image1.gif"/>
</form>
the image input becomes the submit button.
:)
Thanks
crptcblade, are you into XML these days. Your syntax seems to be somewhat similar to what I know of XML.
crptcblade
Dec 1st, 2001, 12:13 AM
Originally posted by amitabh
Thanks
crptcblade, are you into XML these days. Your syntax seems to be somewhat similar to what I know of XML.
Yeah, I used XML for a while, so I just got used to closing single tags. That way, if I needed to make a style sheet out of existing HTML, I don't need to go back and put them in anyway.
:)
vbforums.com
Copyright Internet.com Inc., All Rights Reserved.