Avinash Singh
Avinash Singh

Reputation: 2785

How to hide the address bar of browser by JavaScript?

I am opening a page in new window of browser, in that i want to hide browser address bar.

My code is:

<a title="View" style="cursor:pointer; text-decoration:underline;" 
    onclick='javascript:window.open("Preview.aspx?File=Artisteer4_User_Manual.swf","_blank","toolbar=no, directories=no, status=no, menubar=no, scrollbars=yes, resizable=no, copyhistory=no,fullscreen=yes, location=0");' 
    >Artisteer4_User_Manual</a>

Upvotes: 3

Views: 3541

Answers (1)

sockfd2
sockfd2

Reputation: 545

You cannot hide the address bar using Javascript.

However, in your case, instead of creating a Javascript popup, you can display your swf file inside a div, which you make visible using Javascript. This will create an illusional popup without address bar.

Your div can then have a close button and a title bar, mimicking a real popup. Besides, you can also specify a unique layout; when using a Javascript popup you are stuck with your browser's title bar.

Upvotes: 5

Related Questions