in reply to How To Disable A Browser's Back Button in CGI.pm?

Disabling the back button, for whatever reason, is very very very very bad web design. The history feature most browsers carry is one of the strong points of the web (being able to go back to where you came from previously), and those that try to disable it for whatever reason and by whatever mean (opening a new window, or using JS), find themselves easily bitten by keyboard commands or other features.

That said, if you don't want a form to be reposted after a user leaves it, assign a unique session id that is generated when you first give the user the form and stored as a hidden field within it. When the form is submitted, toggle this sessionid as 'done', and if the form is resubmitted, you can easily check if that session id has already been procesed or not. (Similar to other ideas already posted).


Dr. Michael K. Neylon - mneylon-pm@masemware.com || "You've left the lens cap of your mind on again, Pinky" - The Brain
  • Comment on Re: How To Disable A Browser's Back Button in CGI.pm?