Page 1 of 1
Opening first page without browser menubar or location bar
Posted: Sun Jul 27, 2003 3:03 pm
by Query
I have been looking for a way to open the first page / index.html in a window without a menu or location bar. I have been down the route of opening a new window and closing the parent with javascript, however the user may be presented with a message box asking if they would like to close the parent window or not. I would rather aviod that. There does not seem to be another client side option - could PHP dictate the window params?
Thanks
Posted: Sun Jul 27, 2003 3:39 pm
by patrikG
Nope. PHP can't do that. It's a security- (or rather) annoyance-issue as well, since I don't want any website to close my main browser-window without my consent.
Posted: Sun Jul 27, 2003 4:08 pm
by Fredix
you should never forget that PHP is server side and the only thing that returns to the browser is generated HTML or JS code, so if can't do anything with the help of HTML or JS , PHP won't help you either.
Posted: Mon Jul 28, 2003 6:12 am
by Query
Hi, yeah I would be annoyed if everyone and sundry closed my main browser window, and I would rather not open a window for the sole purpose of opening another window - just as annoying!
What I was looking for was a way to send the equivalent of the javascript instruction without sending a page - possibly as a header??, although I'm fairly sure that these parameters can only passed as an argument when creating a new instance of the browser (although why I do not know). I'm trying to create an app with it's own tool bars etc and I imagine that I am not alone in wanting to do this...
Anyway if anyone has any additional info, I would appreciate it!!!
Thanks for the replies
-Q
Posted: Mon Jul 28, 2003 6:20 am
by patrikG
You can submit a form to a new window with e.g.
Code: Select all
<form target="_blank" action="myPage">
<input type=submit>
</form>
Posted: Mon Jul 28, 2003 6:24 am
by mikusan
I ONLY use it once in my whole website and found it useful. I also hate when my bars disappear, but if you have a login popup window or whatever and the size is smaller than 100 by 100 then the bar just becomes too clumsy and big.
What you are looking for is the following code, i think:
Code: Select all
<BODY onLoad=open("''something.php'',''miniwin'',''toolbar=0, location=1, directories=0, status=0, menubar=0, scrollbars=0, resizable=0, width=450, height=470, target=blank'')">
Yes popups ARE annoying but this is one option you have, considering what your first page is designed to do. You can also use a link to do this. I don't think that you can suddenly get rid of your main page's adress bar and such, ( i would like to be proven wrong) because then people could save a copy of the page on the HD and then comment out your javascript and there you go you still have them...
[Admin Edit]Added spaces in the JS code to allow it to wrap.[/Edit]