Welcome Guest, Not a member yet? Register   Sign In
Reload Problem, user tend to submit data twice
#11

[eluser]obiron2[/eluser]
but in that example you are not creating a unique database record. If it were a user registration form and the form was processes sucessfully and then the user hits F5 to refresh the page, the $_POST data will be re-submitted and unless you have uniqueness checks turned on in your database or validate for the hidden field you will repost the data.

I have thought of a solution but not tried it yet.

If you open the form URL with target="_new" it will open in a new window. If the data is sucessfully submitted you should be able to call a js script as part of the onLoad() function to $this.window.close()

(Don't quote me on the syntax...)

This way the window will shut itself down when successful and the $_POST will be destroyed.

Obiron


Messages In This Thread
Reload Problem, user tend to submit data twice - by El Forum - 10-28-2007, 03:14 AM
Reload Problem, user tend to submit data twice - by El Forum - 10-28-2007, 05:11 AM
Reload Problem, user tend to submit data twice - by El Forum - 10-28-2007, 08:42 AM
Reload Problem, user tend to submit data twice - by El Forum - 10-28-2007, 09:24 AM
Reload Problem, user tend to submit data twice - by El Forum - 10-28-2007, 09:28 AM
Reload Problem, user tend to submit data twice - by El Forum - 10-28-2007, 10:00 AM
Reload Problem, user tend to submit data twice - by El Forum - 10-28-2007, 10:37 AM
Reload Problem, user tend to submit data twice - by El Forum - 10-28-2007, 10:24 PM
Reload Problem, user tend to submit data twice - by El Forum - 10-29-2007, 05:37 AM
Reload Problem, user tend to submit data twice - by El Forum - 10-29-2007, 08:38 PM
Reload Problem, user tend to submit data twice - by El Forum - 10-30-2007, 03:05 AM
Reload Problem, user tend to submit data twice - by El Forum - 10-30-2007, 06:05 AM
Reload Problem, user tend to submit data twice - by El Forum - 10-30-2007, 07:59 AM
Reload Problem, user tend to submit data twice - by El Forum - 10-30-2007, 10:07 AM
Reload Problem, user tend to submit data twice - by El Forum - 10-30-2007, 01:04 PM
Reload Problem, user tend to submit data twice - by El Forum - 10-30-2007, 01:51 PM
Reload Problem, user tend to submit data twice - by El Forum - 10-30-2007, 02:19 PM
Reload Problem, user tend to submit data twice - by El Forum - 10-30-2007, 04:06 PM
Reload Problem, user tend to submit data twice - by El Forum - 12-11-2007, 05:06 PM
Reload Problem, user tend to submit data twice - by El Forum - 12-11-2007, 05:51 PM
Reload Problem, user tend to submit data twice - by El Forum - 04-29-2008, 12:01 PM
Reload Problem, user tend to submit data twice - by El Forum - 09-23-2009, 09:34 PM
Reload Problem, user tend to submit data twice - by El Forum - 09-24-2009, 07:40 PM



Theme © iAndrew 2016 - Forum software by © MyBB