简体   繁体   中英

how to show modal popup window in opera using javascript

i am able to show the madal popup window using javascript in IE using the following code:

var retVal = window.showModalDialog(PagePath, null, 'dialogWidth:850px;dialogHeight:870px;resizable:no;status:no;help:no;scroll=yes');

but its not working in Opera. Though I am able to open a window in Opera using window.open but i am not able to get the return value.

I am putting the return value in a hidden field and from code behind I am rediecting to the specified page based on the retun value (value in the hidden field).

AFAIK showModalDialog is an IE specific method. If you want a modal box in other browsers, you'll have to program one yourself. Maybe this jsfiddle can get you started.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM