Why does the below script cause the form to submit twice? I can’t figure this out, even after trying other solutions posted around the internet. Submitting twice is causing duplicate entries in the database. Thank you in advance for looking into this! <script type="text/javascript"> $(document).ready(function(){ $('#form-error').hide(); $("#form-submit").click(function(){ $("#form").submit(); }); }); $('#form').submit(function(e) { register(); e.preventDefault(); }); […]
The post Why does Ajax form submit twice? appeared first on BlogoSfera.