Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

IE 4 - Target=blank force browser to open full screen

Posted on 1998-09-18
6
Medium Priority
?
5,417 Views
Last Modified: 2008-03-03
When targeting a new window with the following:
<A href="page.htm" target="_blank">Click here</a>

Is there a way to force the browser to open maximized>
0
Comment
Question by:dejthor
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
6 Comments
 
LVL 12

Expert Comment

by:Otta
ID: 1837937
It can be done, if the user's browser supports JavaScript,
and the user has not disabled JavaScript.
0
 
LVL 8

Accepted Solution

by:
jbirk earned 200 total points
ID: 1837938
Yes, with Javascript you would use something like this:
<A href="javascript:void(0); onClick="window.open('page.htm','new_win','fullscreen,status,buttons,location');" >Click here</a>
That will open it into fullscreen mode and will only do this for IE 4.  If you want it to be maximized you can't truly 'maximize' it but you can make it's size the size of the screen, assuming that the user has netscape 4+ or IE 4+.  That would look something like this:
<A href="javascript:void(0); onClick="max_open();">Click here</a>
<SCRIPT language="JavaScript1.2">
<!-- cloak
x=screen.width;
if (x<=640) //640X480 screen
 window.open('page.htm','new_win',width=640,height=480,status,buttons,location');
else if (x<=800) //800X600 screen
 window.open('page.htm','new_win',width=800,height=600,status,buttons,location');
else if (x<=1024) //1024X768 screen
 window.open('page.htm','new_win',width=1024,height=768,status,buttons,location');
//and any other resolutions I missed??
// decloak -->
</SCRIPT>


Hope this is helpful,
Josh
0
 
LVL 1

Author Comment

by:dejthor
ID: 1837939
When using the following:
<A href="javascript:void(0); onClick="window.open('page.htm','new_win','fullscreen,status,buttons,location');"

Two undesired results. First, while in full screen mode, there are no toolbars. Second, the frame that contains the href canges from a list hyperlinks to [object].

0
Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

 
LVL 8

Expert Comment

by:jbirk
ID: 1837940
OK, well the second problem was a simple caused because I missed a quote.  It should be:
<A href="javascript:void(0);" onClick="window.open('fullscreen.html','new_win','fullscreen,status,toolbar,location');">New fullscreen window</A>
Notice the quote after javascript:void(0);

The first problem I can't do anything about because apparently IE's fullscreen mode overrides any other requests for window features.  So basically there's nothing you can do about it if you want fullscreen mode.

You can always use something like this which will increase the window to the size of the screen and move it to starting in the upper left: (4+ browsers only)
<A HREF="javascript: if (window.resizeTo) window.resizeTo(screen.availWidth,screen.availHeight); if (window.moveTo) window.moveTo(0,0);">Fullscreen me</A>
That basically maximizes the current window. and doing this:
<BR><A href="javascript:void(0);" onClick="new_win=window.open('fullscreen.html','new_win','status,toolbar,resizable,location,scrollbars'); if (window.resizeTo) new_win.resizeTo(screen.availWidth,screen.availHeight); if (window.moveTo) new_win.moveTo(0,0);">new fullscreen window</A>
would open a new maximized window.

Note that the above two methods work like a charm in IE 4, but not quite as well N 4.  In netscape, it makes the window bigger than the available space, even though that is what we told it to use.

-Josh
0
 
LVL 1

Author Comment

by:dejthor
ID: 1837941
OK using the following:
<A href="javascript:void(0);" onclick="window.open('../rosters/rosterall.htm','new_win','status,toolbar,resizable,location,scrollbars'); if (window.resizeTo) new_win.resizeTo(screen.availWidth,screen.availHeight); if (window.moveTo) new_win.moveTo(0,0)" onmouseover=rollon(); onmouseout=rolloff(); border = 0><SPAN class =Item>All Teams</SPAN></A>

Generates an error: new_win is undefined.
0
 
LVL 8

Expert Comment

by:jbirk
ID: 1837942
You missed some of it in your copy paste.  Look above, I posted this:
<BR><A href="javascript:void(0);"
onClick="new_win=window.open('fullscreen.html','new_win','status,toolbar,resizable,location,scrollbars'); if (window.resizeTo) new_win.resizeTo(screen.availWidth,screen.availHeight); if (window.moveTo) new_win.moveTo(0,0);">new fullscreen window</A>

You left out the part that defines new_win at the beginning of the onClick action
("new_win=window.open....)

-Josh
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article demonstrates how to create a simple responsive confirmation dialog with Ok and Cancel buttons using HTML, CSS, jQuery and Promises
This article explains how to prepare an HTML email signature template file containing dynamic placeholders for users' Azure AD data. Furthermore, it explains how to use this file to remotely set up a department-wide email signature policy in Office …
In this Micro Tutorial viewers will learn how to create navigation buttons that change on rollover, using CSS (Continuation of the CSS Image Sprite tutorial) Create a parent ID for all the list items       - Specify position: absolute and display: block…
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

609 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