Home Ask Login Register

Developers Planet

Your answer is one click away!

l vialaret February 2016

real modal confirm jquery

My question is really simple and stupid, but it's impossible for me to find an answer: I just want to replace js confirm with a nice dialog box. but it seems impossible to do this simple thing in jQuery:

function ..... () {
    alert (1);
    confirm ( "some question" );
    alert (2);

the script shows "some question", stops and waits for user input, then continues after.

Is it really impossible in jQuery (please do not answer with confirm plugin, pseudo modal plugin, or even deffered ... ==> they do not do the same as js confirm)?

And if it's impossible in jQuery, is there another way to do this?


Jon Surrell February 2016

confirm and alert depend on the browser and the underlying operating system. The browser is responsible for opening them and there is no way to style them or otherwise modify the behavior.

Post Status

Asked in February 2016
Viewed 3,066 times
Voted 8
Answered 1 times


Leave an answer

Quote of the day: live life