Welcome Guest, Not a member yet? Register   Sign In
Multiple form submissions
#1

[eluser]Unknown[/eluser]
I am looking for a way to intelligently handle what happens when a user repeatedly pounds on a form's submit button. Is there anything built into CI that can help with this?

I've been considering seeding the form with a secret code that's also stored in the session. When the form gets submitted with a code that matches the code that's in the session, processing is done and the session code is cleared, which causes extra submits to be ignored. The problem with this is that if the user then goes back to the original form via the back button, retrieving the page from the cache, complete with the orignal secret code, and tries to submit a new form, perhaps with different info, the submission will be ignored.

I've also considered javascript solutions, such as disabling the submit button, but there's no guarantee the user will have javascript enabled and server-side logic would be required anyhow.

Any thoughts would be greatly appreciated!


Messages In This Thread
Multiple form submissions - by El Forum - 09-08-2007, 12:54 PM
Multiple form submissions - by El Forum - 09-08-2007, 06:15 PM



Theme © iAndrew 2016 - Forum software by © MyBB