Welcome, Guest
Username: Password:

TOPIC: PSA: Custom javascript mandatory logic reandomly breaking

PSA: Custom javascript mandatory logic reandomly breaking 1 year 8 months ago #112140

  • Bigred
  • Bigred's Avatar
  • Offline
  • Senior Lime
  • Posts: 69
  • Thank you received: 26
  • Karma: 5
Hey Everyone. I have had an issue with small number of random people using random browsers/browser versions getting past some of my custom javascript manadatory logic.

For these questions i usually run through a few if statements and if the question has not been answered properly i will throw up an alert and return false.

It seems that if someone tries to move forward multiple times and checks the option (if their browser offers it) to suppress all further alerts for the page they are on, the script will break at the alert and the form will submit.

I am now using preventDefault() on form submits when i run custom logic and i submit the form myself if the logic is true (which i should have been doing from the start :blush:).

This is just a heads-up for everyone who may have had or is having the same issue.
The administrator has disabled public write access.
Moderators: ITEd
Time to create page: 0.178 seconds