Questions tagged [double-submit-problem]

Double submit problem. Submission of the same data more than once in a POST request.

Two most frequently used HTTP request methods are GET and POST. GET method retrieves resource from a web server. Resource is identified by base location and optional query parameters. Generally, parameters of GET request are used to narrow the result and do not change server state. The same GET request can be sent to the server as many times as needed.

On the contrary, parameters of POST request usually contain input data, which can change state of server application. Same data submitted twice may produce unwanted results, like double withdrawal from a bank account or storing two identical items in a shopping cart of an online store. Submission of the same data more than once in a POST request is undesirable and got its own name: Double Submit problem.

53 questions
20
votes
7 answers

How do you prevent a user from posting data multiple times on a website

I am working on a web application (J2EE) and I would like to know the options that are available for handling a double post from the browser. The solutions that I have seen and used in the past are all client-side: Disable the submit button as soon…
Rontologist
  • 3,568
  • 1
  • 20
  • 23
19
votes
2 answers

Html.RenderPartial and Ajax.BeginForm -> Submit is called twice

I have the following index view: @model BoringStore.ViewModels.ProductIndexViewModel @{ ViewBag.Title = "Index"; }

Produkte

@{ Html.RenderPartial("Create", new BoringStore.Models.Product()); }
14
votes
7 answers

IE9 Double Form Submit Issue

I am just wondering if anyone have some info or feedback about the situation I am in. Currently I am facing a "Double Form Submit" issue, where I click the "Submit" button once, and it submit the form twice. This only happens in IE9, but I have only…
forestclown
  • 1,582
  • 4
  • 25
  • 39
14
votes
8 answers

In rails controllers, how to prevent double submit (when user double-clic submit button or hit enter twice)?

Well, everything's in the title but I'll explain a little more :-) My rails app contain many forms (Ajaxified or not). To prevent users to submit twice or more some forms, I use Javascript. There's my scenario for a Ajaxified form : the user submit…
fro_oo
  • 1,610
  • 4
  • 24
  • 46
10
votes
4 answers

Why is my form submitting twice?

SO for some reason my form is submitting two times with a single button press. This is my first time using jquery Form plugin, and I imagine that jquery is submitting once and the form is "naturally" submitting as well. I have seen that the remedy…
7
votes
4 answers

Form submitted twice in Chrome/Safari

I am seeking to perform a basic form post, but the following submits to the server twice in Chrome and Safari (but behaves as expected in Firefox):
Create new…
meg
  • 151
  • 2
  • 10
5
votes
3 answers

IE submit the forms twice

I have this problem in IE, sometimes my form is submitting twice. I know the issue of clicking the button twice and that is not the problem. But on my case I only click it once. I checked my records in the database and there are two records.
Paengski
  • 339
  • 2
  • 6
  • 15
3
votes
4 answers

Jquery - Internet Explorer submitting form twice

I have the following code which I use to submit forms with links (instead of buttons). This is so that we can do some CSS hover stuff with them. $('a.css_submit').click(submit_form); $('a.inactive_submit').click(submit_form); function…
Kevin Whitaker
  • 12,435
  • 12
  • 51
  • 89
3
votes
2 answers

jQuery Submit Event Happens Twice

My jQuery submit() event is firing twice, and I don't know why. I'm using a templating engine to build my HTML dynamically so I end up calling $(document).ready() multiple times, as follows...