views:

550

answers:

1

Hi! I want to open a popupwindow (with close button only) when the user clicks a button and the parent window should be disabled until the popup window closed. For that I'm using the following code

function popup_window(url) {

     popupwin = window.showModalDialog(url,null,'height=20,width=150,status=no,resizable=no,scrollbars=no,toolbar=no,location=no,menubar=no');     
     }

Anyhow, this code is working perfectly in IE. But, I hav two problems. In firefox, it is not opening with the size I've mentioned in the script. It is opening in full size. And In Google Chrome, parent window is not getting disabled.

Thanks in Advance

A: 

The syntax of the args is different. For example:

window.showModalDialog(url, null, 
"dialogwidth: 150; dialogheight: 20; resizable: no")
Anonymous
I tried.. Working properly in firefox. But, now IE is getting too large for that size..
Nila