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!

OnClick call asp file

Status
Not open for further replies.

testare

Programmer
Jan 21, 2005
127
I would like to call the insert action where pressing the button.
Code:
<%If Request.QueryString ("action") = "insert" Then		
	Response.Write("okok")
End If%>

<input type="button" value="Post" onClick="cal.asp?action=insert">

I'm i thinking wrong?
 
Well, the only issue I see is that you need to assign that address to something, like maybe location.href. That way it will load the page as it appears you want it to.

-T

barcode_1.gif
 
I tried it like this.
onClick='location.href.button.asp?action=insert'
But it didn't work.
How should i type it?
 
It works now, Tarwin.
onClick="location.href='button.asp?action=insert'"

Thanx
 
Not a problem, sorry I didn't get back quicker to help with that last step.

barcode_1.gif
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top