Frage

When a user tries to close the browser window a popup box pops up. But the problem with that is, it displays its own popup data. So please let me know how can I customize it content of popup box in "Firefox".

 window.onbeforeunload = function() {
      return "my text";
 };

Here instead of "my text" it is displaying its own data. Note: its working fine in Chrome!

Thank you.

War es hilfreich?

Lösung

You can't... not in FF

Note that in Firefox 4 and later the returned string is not displayed to the user. See bug 588292.*

The only solution is create a custom modal box and give some CSS style to that DIV (for example...)

Source: developer.mozilla.org

Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top