Welcome to WebmasterWorld Guest from 54.146.211.105

Forum Moderators: open

Message Too Old, No Replies

javascript redirect for custom alert

     
5:08 am on Dec 13, 2007 (gmt 0)

New User

10+ Year Member

joined:Apr 21, 2005
posts:24
votes: 0


Javascript question
I have a link on my website "click here to purchase" when customer clicks on it he gets a custom alert window saying 'you are going to purchase the item xyz. click on ok to proceed or cancel to cancel'The user should here point to purchase.aspx after clicking on ok. This custom alert points to different locations for different links like purchase.aspx, query.aspx etc for each page custom window. plz tell me how do I write the javascript for the same.

here is the sample code
<div id="alertcustom">
<p>'you are going to purchase the item xyz. click on ok to proceed or cancel to cancel'</p>
<form id="form1" action="#" onsubmit="xyz();">
<input id="OK" class="okbutton" name="OK" value="OK" type="submit" />
<input id="Cancel" class="cancelbutton" name="Cancel" value="Cancel" type="submit" />
</form>
</div>

Thanks - Vicky....

6:16 am on Dec 13, 2007 (gmt 0)

Senior Member

WebmasterWorld Senior Member 10+ Year Member

joined:Nov 3, 2005
posts:1585
votes: 0


Like this maybe?

<form id="form1" action="/purchase.aspx?item=xyz" >