Too Cool for Internet Explorer

Tuesday, June 14, 2005

Browser Window Size Reset

You may recall a previous entry in which I lamented about web sites that use a Javascript function to change my browser window to the size they think it should be. It never previously occurred to me that I can use the exact same function to restore my desired settings. Yes, I know if I used something like Firefox instead of Safari, I could make myself immune to resized windows, but I still prefer Safari, for now.

The trick is to simply save a bookmark with the following Javascript line as the URL:


You’ll need to change the four variables inside the parenthesis to your preferences. The ‘w’ and ‘h’ should be set to the desired width and height, and the ‘x’ and ‘y’ values correspond to the upper left corner of your window, thus 0,0 is the top left corner of your screen.

For quick access, I placed this bookmark in my toolbar below the URL bar, and simply named it with a period character so that it takes as little space as possible.

» Posted by ALBj at 11:27 PM (ET)
Category: Cool Technology


Just out of curiosity, what IS the javascript to set the initial browser window size? I don’t mean “click a link and open a NEW window of such and such a size”, but the code to set the INITIAL size of a window, as it’s loading. Say, when someone types in the address bar and my home page starts loading, how can I make the initial size what I want? Though some uses can be annoying, I have an innocuous need for it on my main site page.

» Posted by Brian Y
July 2, 2005 07:07 PM

If you’re asking what I think you’re asking, I don’t even care to find the answer—allow me to refer you to:

» Posted by Lee Bennett
July 2, 2005 07:39 PM

I was trying to .. I haev this collapse expand script.. that collapses an area.. I have like 30 areas.. and when they all collapse at first - it leaves a blank at the bottom of the page- so i need to figure out how to “refresh” the window.. if I resize it manually via the browser it works fine.. anyway.. argh.. javascript is sweet still.

» Posted by Leo Charre
September 21, 2005 03:24 PM

Sorry, due to comment spam abuse, new comments on this entry are closed until I find time to upgrade Movable Type and enable registration and moderation.