JavaScript : Open, Close, and Modify Browser Windows
Contents ]
Dr Benton

All Window Display Options

The customising possibilities with JavaScript are not limited to changing the WIDTH and HEIGHT properties. Other optional parameters are available to activate or deactivate some aspects of the window simply by assigning the value YES or NO to the appropriate parameter. The default value when you do not use these parameters is NO.

The following figure and table summarise all the possibilities open to you.



Figure 1: Window display options.



Activation / deactivation of ... Property
- status bar (1) status
- link bar (2) directories
- tool bar (3) toolbar
- address bar (4) location
- menu bar (5) menubar
- scroll bars (6) scrollbars
- resizing handles (7) resizeable


The following example opens the same window, this time with a status bar and a tool bar, but without link bar, menu, scroll bars and resizing handle.

<A HREF="javascript:void(0)" onClick="MyWindow = window.open('stracy.jpg','Spencer','width=190,height=210, status=yes, directories=no, toolbar=yes, location=no, menubar=no,scrollbars=no, resizable=no');" >Another window</A>

Another window