Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP General > Request.Servervariables("HTTP_REFERER") versus BACK button on browser

Reply
Thread Tools

Request.Servervariables("HTTP_REFERER") versus BACK button on browser

 
 
JJA
Guest
Posts: n/a
 
      10-26-2004
When my webserver does not process a user's change because of an
invalid password, I inform the user and I want to present them a
button for a retry:

<TR id=continuebuttonrow>
<td width="05%">&nbsp;</td>
<TD width="90%" align=center valign=middle colspan=2>
<BUTTON TYPE=BUTTON
ONCLICK="location.href='<% =
Request.ServerVariables("HTTP_REFERER") %>';"
class=btnParms name=btnContinue ID="Button3">Try Again (Back)</BUTTON>
</td>

Yet if this button is clicked, they go back to the server and the page
is refreshed with original values.

If I click the browser's BACK button (rather than my button above), I
go back to the page (from cache I guess) I want (because it contains
the user changes). Here I can correct the password without having to
rekey the changes.

So, what is the Request.Servervariable needed for the equivalent of
the BACK button? Thanks.
 
Reply With Quote
 
 
 
 
Aaron [SQL Server MVP]
Guest
Posts: n/a
 
      10-26-2004
You would use client-side script only, e.g.

onclick='window.history.back();'

--
http://www.aspfaq.com/
(Reverse address to reply.)




"JJA" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed) om...
> When my webserver does not process a user's change because of an
> invalid password, I inform the user and I want to present them a
> button for a retry:
>
> <TR id=continuebuttonrow>
> <td width="05%">&nbsp;</td>
> <TD width="90%" align=center valign=middle colspan=2>
> <BUTTON TYPE=BUTTON
> ONCLICK="location.href='<% =
> Request.ServerVariables("HTTP_REFERER") %>';"
> class=btnParms name=btnContinue ID="Button3">Try Again (Back)</BUTTON>
> </td>
>
> Yet if this button is clicked, they go back to the server and the page
> is refreshed with original values.
>
> If I click the browser's BACK button (rather than my button above), I
> go back to the page (from cache I guess) I want (because it contains
> the user changes). Here I can correct the password without having to
> rekey the changes.
>
> So, what is the Request.Servervariable needed for the equivalent of
> the BACK button? Thanks.



 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
After gmail logs out, cannot go back through browser back button Author ASP .Net 6 01-22-2009 03:24 PM
Re: Mozilla versus IE versus Opera versus Safari Peter Potamus the Purple Hippo Firefox 0 05-08-2008 12:56 PM
equal? versus eql? versus == versus === verus <=> Paul Butcher Ruby 12 11-28-2007 06:06 AM
disable the back button provide the users with my own button to go back. sylvia sil ASP .Net 1 12-29-2004 04:41 PM
submit button versus regular button Matt ASP General 1 03-06-2004 04:53 AM



Advertisments