how can we disable resizing of new popup window in firefox?

前端 未结 4 789
野趣味
野趣味 2020-12-06 03:35

I tried opening a new window using

window.open(\"lookup.htm\",\"lookupWin\", \"height=400,width=500,resizable=false\");

It works fine in IE

相关标签:
4条回答
  • 2020-12-06 03:38

    I don't think you can. Firefox (and some other browsers) just ignore the "resizable" setting.

    0 讨论(0)
  • 2020-12-06 03:40

    Yes it doesn't work anymore. Try

    <script type="text/javascript">
    window.onresize = function() 
    {
        window.resizeTo(500,500);
    }
    window.onclick = function() 
    {
        window.resizeTo(500,500);
    }
    </script>
    
    0 讨论(0)
  • 2020-12-06 03:43

    you con configure dom.disable_window_open_feature.resizable to value false, in order to make window.open re sizable work.

    1. Type about:config
    2. Accept the warning
    3. Search by typing resize and press enter ,
    4. Look for dom.disable_window_open_feature.resizable
    5. double click to change the value. false -> you can not resize the popup in firefox.
    0 讨论(0)
  • 2020-12-06 03:50

    Read this one from mdc

    Window functionality features

    resizable

    If this feature is set to yes, the new secondary window will be resizable.

    Note: Starting with version 1.4, Mozilla-based browsers have a window
    

    resizing grippy at the right end of the status bar, this ensures that users can resize the browser window even if the web author requested this secondary window to be non-resizable. In such case, the maximize/restore icon in the window's titlebar will be disabled and the window's borders won't allow resizing but the window will still be resizable via that grippy in the status bar.

    Starting with Firefox 3, secondary windows are always resizable

    Bug 177838 - Make all popup windows resizable, ignoring resizable=no

    0 讨论(0)
提交回复
热议问题