views:

157

answers:

3

I would like dynamically (via JavaScript) hide the address bar. I realize this can be done when opening a pop-up, but in this case I don't have the luxury (the file is being opened from local disk and I don't want the address bar to show the horrible and confusing file:// etc URL).

Is this possible, and if so, how?

+2  A: 

It isn't possible to change those settings once the window is open. Imagine how annoying that would be if sites could remove the address bar to stop you from leaving their site. In my experience most users never look at the address bar once they have plunked facebok.com into it.

stimms
+1  A: 

Don't forget that IE is not the only browser in the world. Firefox, for example, shows the address even in popup windows.

This behaviour is by design. Pages are not supposed to interfere with the browser chrome too much. Therefore, even if you find a way to suppress the address bar for a given browser, you may find it stops working in future patches.

Think how much easier it would be to operate phishing attacks if you could trivially conceal the location of the document from the user...

Colin Pickard
Absolutely understand the point, but in this case I was hoping it would be possible (rather than believe it is desirable in general). Thanks for the help.
buggles
+1  A: 

If your code will always be running from local disk you can hide the title bar and the address bar using an HTA.

Sheng Jiang 蒋晟

related questions