You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by jalal udeen <ja...@gmail.com> on 2007/05/08 07:30:46 UTC
how to disable refresh button and back button
hi all
can any one explain me how to disable both back button
and refresh button
thanks
jalaludeen
RE: how to disable refresh button and back button
Posted by Al Sutton <al...@alsutton.com>.
I think I know what the guy is after and it's not browser dependant or
impossible, but it's not pretty :).
Basically what you have to do is have a one time ID that changes during each
request and then verify that the requests one time ID is correct. So the
flow looks like this;
1) Create new One Time ID (I'll call it otid)
2) Store otid in the users session
3) Append otid as a parameter to the links to the actions you wish to
protect.
(user then clicks on link).
4) Verify otid from url parameter equals otid from session.
5) Go to step 1
This means that if the user clicks refresh or back they will request the
action with an old one time id and thus the system can generate an error at
step 4.
As I said, it's not pretty.
Al.
-----Original Message-----
From: Adam Ruggles [mailto:a.ruggles@gmail.com]
Sent: 08 May 2007 06:38
To: Struts Users Mailing List
Subject: Re: how to disable refresh button and back button
I don't believe you can.
jalal udeen wrote:
> hi all
> can any one explain me how to disable both back
> button and refresh button thanks jalaludeen
>
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org
Re: how to disable refresh button and back button
Posted by Adam Ruggles <a....@gmail.com>.
I don't believe you can.
jalal udeen wrote:
> hi all
> can any one explain me how to disable both back button
> and refresh button
> thanks
> jalaludeen
>
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org
Re: how to disable refresh button and back button
Posted by Michael Jouravlev <jm...@gmail.com>.
On 5/7/07, jalal udeen <ja...@gmail.com> wrote:
> hi all
> can any one explain me how to disable both back button
> and refresh button
This is browser-dependent and does not relate to Struts.
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org