QUESTION
How can I detect if a user has checked the box, "prevent this page from creating additional dialogs"?
WHY It's a problem
If the user has prevented the appearance of confirm boxes, the function confirm('foobar')
always returns false.
If the user cannot see my confirmation dialogue boxes confirm('Are you sure?')
, then the user can never perform the action.
CONTEXT
So, I use the code like if(confirm('are you sure?')){ //stuff... }
. So an auto-response of false
from the browser will prevent the user from ever doing stuff
. But, if there was a way to detect that the user has checked the box, then I could execute the action automatically.
I think that if the user has disabled the dialogues, then the function should either throw an error, or return true. The function is meant to confirm an action that the user has requested.