Hi gang:

This is probably trivial for most of you, but here's my solution to the problem I presented earlier.

The problem was, I just wanted to be certain that if a use clicked a button that they could only do it once. Sounds simple enough, huh?

Certainly, one can use javascript, but I wanted something that was basic php and html -- here's my solution with code (please provide critical review):

http://www.webbytedd.com/cc/submit-once/index.php

If the user clicks "Submit once", then that's the way it is until they quit their browser. If they don't quit their browser, then no amount of refresh will allow them to click the button again.

The "Reset Submit", of course, resets this condition but it's for demo purposes.

What I have not solved, and I don't think there is a solution (I could be wrong) is to prohibit the user from clicking the back button on their browser to reset this condition.

I've done a considerable amount of javascript reading, testing, and code search and have not found anything that works -- and -- I have even found places where the js community says that nothing will work to solve the back-button problem.

So, does anyone here know better? If so, please start a different thread.

Cheers,

tedd

--
-------
http://sperling.com  http://ancientstones.com  http://earthstones.com

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to