Welcome to WebmasterWorld Guest from

Forum Moderators: ocean10000

Message Too Old, No Replies

Shell command to control browser window controls

browser window controls

8:15 pm on Mar 29, 2012 (gmt 0)

New User

5+ Year Member

joined:Aug 21, 2007
posts: 20
votes: 0

Hi All:

I am building an autorun file for a cd to launch a webpage in a users default browser that will display an html menu of the items on the CD.

I am OK with using a basic shell command to launch a file in a browser, however ideally I would also like the ability to strip the browser of all control (menus, navigation etc) and set height and width etc. and I am stuck.

I am also familiar with opening a browser using javascript in a webpage but not using the windows scripting host or wscript.exe.

Any help/guidance would be greatly appreciated.

1:59 am on Mar 31, 2012 (gmt 0)


WebmasterWorld Administrator 10+ Year Member Top Contributors Of The Month

joined:Jan 14, 2004
votes: 0

One of the methods I found on the net, was a two file solution. This works some times but fails if a popup blocker stops it.

The initial file which is launched by the auto run, and your menu html file.

The initial file calls a javascript method which opens a new window (your menu) and closes the original window. Some web browser popup blockers will stop this.

This function is in the initial html file called from the autorun.

function openWindow(){
var browser=navigator.appName;
if (browser=="Microsoft Internet Explorer"){
window.open('popup.html', 'null', 'width=900,height=750,toolbar=no,scrollbars=no,location=no,resizable =yes');
parent.close(); //Closing on the child

This can be called from the body onload method.


The reason that this two file method approach is required, is that modern web browsers unless you open a new window you can not remove the scroll bars and other features from the currently active window.

Window open() Method [w3schools.com]
6:35 pm on Apr 3, 2012 (gmt 0)

New User

5+ Year Member

joined:Aug 21, 2007
posts: 20
votes: 0

I'll give this a try. Thank you!