How to create TRULY modal alerts/confirms in Javascript?

后端 未结 2 1098
别那么骄傲
别那么骄傲 2021-01-24 05:15

I am sifting through prompt() and confirm() replacements for JavaScript. I need to create a couple of confirm()s and alert()s that have three or more o

2条回答
  •  广开言路
    2021-01-24 06:00

    Both IE and Firefox 3 have a showModalDialog method which would allow you to display an entire web page modally. However for a truely cross-browser solution you can't use that.

    Many of the popular frameworks provide a mechanism to do it by displaying a HTML element and disabling access to the rest of the web page whilst the element is displayed.

提交回复
热议问题