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 gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Opting out of ASP Page

Status
Not open for further replies.
Apr 27, 1999
705
US

Hello,
I have an ASP page that runs this javascript at the beginning. I would like to the user to option out of the ASP page. The code below redirects me to the correct page but it still processes the rest of the ASP page. Any ideas?

Thanks
fengshui_1998


<script language=&quot;javascript&quot;>
var clickok = window.confirm(&quot;This page will begin processing orders.\n Click OK to continue. Click Cancel to stop.&quot;);

if (clickok == false) { document.location=&quot;MyAdmin.asp&quot;;}
</script>
 
The ASP is processed before the generated HTML and Javascript ever hit the user's browser.

One possible solution: insert an intermediate page which asks if the user wants to &quot;process&quot; or &quot;stop&quot;, then redirects either to the page which processes the orders, or to your admin page which does not. Hope this helps.
Ciao, K----------------
&quot;If you were supposed to understand it, we wouldn't call it code&quot; - FedEx
 
kim1234,

Duh! I knew that! I had a brain freeze on! Thanks for your help!


fengshui_1998
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top