Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

submit form with a href tag... 2

Status
Not open for further replies.

spewn

Programmer
May 7, 2001
1,034
0
0
i don't like the eyesore submit button, would like to use a link to submit.


- crispy
 
How about an image instead?

<input type=&quot;image&quot; src=&quot;submit.gif&quot;>

This works as a submit button. Dean Owen
 
You can use an actual anchor like this:

<a href=&quot;#&quot; onClick=&quot;document.formName.submit();&quot;>Click here to submit</a>

Or, I like to use a span, and then just format the text like:

<span onClick=&quot;document.formName.submit();&quot; style=&quot;cursor: hand&quot;><font color=blue><u>Click here to submit</u></font></span>

Only difference, really is the lack of a *click* when they click on the span, but it looks the same -- oh, and it won't change colors when they come back to the page.

:)
Paul Prewett
 
With this method can you pass a value depending on which link is clicked?


The form is <form name=&quot;orderForm&quot; action=&quot; method=&quot;post&quot;>

The submit button I have at the moment is: <input type=&quot;submit&quot; value=&quot;Hardware&quot; name=&quot;Category&quot;>

Is it possible to have a
<a href=&quot;#&quot; onClick=&quot;document.formName.submit();&quot;>Click here to submit</a>

That will submit the same as the above Submit button?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top