Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

New windows in tab browser don't work

Status
Not open for further replies.

nchan

Programmer
Jan 9, 2001
40
CA
Is there anyway to force a tab set browser to popup a new window of a specific size 200pixels x 200 pixels? Needed purely for presentation purposes to allow the viewer to view samples. Seems that the scripts for specifying window options don't work either. Am I missing something or is that the new standard of browsing and we'll have to chuck all those scripts?

Thanks,'nchan
 
Popup blockers aside, the window.open parameters to size and position windows do still work. Are you using the correct syntax? Are you sure your code isn't incorrect?

This should work:

Code:
window.open('[URL unfurl="true"]http://www.google.co.uk/',[/URL] '', 'width=200,height=200,left=50,top=50');

Hope this helps,
Dan

[tt]Dan's Page [blue]@[/blue] Code Couch
[/tt]
 
Currently I am using this script.

<script language="JavaScript" TYPE="text/javascript">
<!--
function openWindow(myLink,windowName)
{
if(! window.focus)return;
var myWin=window.open("",windowName,"height=150,width=150,dependent=yes,scrollbars=no");
myWin.focus();
myLink.target=windowName;
}
//-->
</script>

with this link

<a href="nwindemo.html" onClick="openWindow(this,'nwindemo')">newwindemo</a>

New windows open in IE 6.0.2900
They open as tabs Netscape 8 and Firefox 1.0.7


puzzled.

 
If you have Netscape and Firefox configured to open new windows as tabbed windows, then new windows (including popups - which are actually new windows) will open in tabs. There is no magic involved.

Confirm your preferences settings for these two browsers.

Cheers,
Jeff

[tt]Jeff's Page [/tt][tt]@[/tt][tt] Code Couch
[/tt]
 
>>Confirm your preferences settings for these two browsers.<<

There lies the problem. I am trying to address the people who don't know that tab viewing is a browser option. That when viewing in tabs 'they' have the mouse option to view a link in a new window (not as a specified size but as full screen).

I would like to force a new 'specified size' window regardless of which browser a user uses. Seems like that isn't possible. I'm thinking the developers are forcing everyone to use tabbed browsing by having it as default instead of having tabs as an option.




 
I don't think anyone is "forcing" people to use tabbed browsing. Most people WANT tabbed browsing, so the default is usually to turn it on. The real problem is that browsers don't seem to know how to determine whether they should open a new tab or a new window on a window.open request, so they do whatever the user has set (or accepted as the default). It seems to me that the browser ought to be able to tell just by the size of the window requested whether it should be a new tab or a popup window and respond accordingly (if their popup blocker is turned off, of course).

Tracy Dryden

Meddle not in the affairs of dragons,
For you are crunchy, and good with mustard. [dragon]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top