Hide Address Bar in Target Window

Posted on 2007-08-08
Last Modified: 2009-02-06
I am attempting to create a link that will open a new window with a given size (say, 1010x600) and with no address bar. I found this code elsewhere in these forums:

<A href="new_page.asp"
return false">New Page</a>

...and it does a great job, except that I ONLY want to restrict the address bar (not the menu bar or toolbar or status bar) and I want to designate the window dimensions. Will someone help me edit the code or tell me it's impossible? ;)

Thank you very much.
Question by:jkunrein
    LVL 13

    Assisted Solution

    Sure that's possible..

    Just an example:'','width=1024,height=768,scrollbars=no,toolbar=no,menubar=no');

    You can have these options:

       1.  width
       2. height
       3. location
       4. status
       5. menubar
       6. directories
       7. toolbar
       8. resizable
       9. scrollbars

    Good luck!
    LVL 4

    Accepted Solution

    Actually, the exact syntax is:'','jsNameOfWin','width=640,height=480,toolbar=no');

    the 1rst param is for the website url, the 2second is the name of the win if you need to refer to it later, and finally the params...
    LVL 48

    Assisted Solution

    LVL 16

    Expert Comment

    That's it.  Except newer browsers are actually preventing the removal of the address bar these days (or at least still having the address somewhere visible in the window).

    LVL 9

    Author Comment

    jonathanmelnick's code worked, except that it shut down all toolbars/scrollbars/status bar and I haven't yet found a way to do those things individually. Still experimenting with information provided by Onthrax and hernst42; thanks for the resources!

    LeeKowalkowski -- Good point. My company is still on IE6 (sorry, I forgot to mention that) but I would rather create something as future-proof as possible.

    Thanks, all!

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    What Is Threat Intelligence?

    Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

    Suggested Solutions

    Have you tried to learn about Unicode, UTF-8, and multibyte text encoding and all the articles are just too "academic" or too technical? This article aims to make the whole topic easy for just about anyone to understand.
    Envision that you are chipping away at another e-business site with a team of pundit developers and designers. Everything seems, by all accounts, to be going easily.
    The viewer will the learn the benefit of plain text editors and code an HTML5 based template for use in further tutorials.
    The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

    779 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    15 Experts available now in Live!

    Get 1:1 Help Now