473,395 Members | 1,516 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

javascript: window.open ie6 vs ie7

Hi,
got a problem, hope someone could help:

this function should open a popup showing an image automatically
adjusting browser window's height and width. It works fine with IE6 but
not with IE7.
In IE7 opens popup too small. why ?

function popImage(imageURL,imageTitle){
if (isNN){imgWin=window.open('about:blank','',optNN); }
if (isIE){imgWin=window.open('about:blank','',optIE); }
with (imgWin.document){
writeln('<html><head><title>Loading...</title><style>body{margin:0px;}</style>');writeln
'<sc'+'ript>');
writeln('var isNN,isIE;');writeln('if
(parseInt(navigator.appVersion.charAt(0))>=4){');
writeln('isNN=(navigator.appName=="Netscape")?1:0; ');writeln('isIE=(navigator.appName.indexOf("Micro soft")!=-1)?1:0;}');

writeln('function reSizeToImage(){');writeln('if
(isIE){');writeln('window.resizeTo(100,100);');
writeln('width=100-(document.body.clientWidth-document.images[0].width);');
writeln('height=100-(document.body.clientHeight-document.images[0].height);');
writeln('window.resizeTo(width+130,height+50);}'); writeln('if
(isNN){');
writeln('window.innerWidth=document.images["George"].width;');writeln('window.innerHeight=document.ima ges["George"].height;}}');
writeln('function doTitle(){document.title="LeMieCime.it di Viali Athos
©";}');writeln('</sc'+'ript>');
if (!AutoClose) writeln('</head><body bgcolor=000000 scroll="no"
onload="reSizeToImage();doTitle();self.focus()">')
else writeln('</head><body bgcolor=FFFFFF scroll="no"
onload="reSizeToImage();doTitle();self.focus()"
onblur="self.close()">');

writeln('<body></html>');

close();

}}
thanks in advance

Oct 6 '06 #1
2 11364

Francesco написав:
Hi,
got a problem, hope someone could help:

this function should open a popup showing an image automatically
adjusting browser window's height and width. It works fine with IE6 but
not with IE7.
In IE7 opens popup too small. why ?
1. Slightly smaller or really small?
2. Remember there is no real release of IE7. Betas and release
candidates may contain bugs.

Val Polyakh
http://trickyscripter.com

Oct 7 '06 #2

sc********@gmail.com wrote:
Francesco написав:
Hi,
got a problem, hope someone could help:

this function should open a popup showing an image automatically
adjusting browser window's height and width. It works fine with IE6 but
not with IE7.
In IE7 opens popup too small. why ?
1. Slightly smaller or really small?
2. Remember there is no real release of IE7. Betas and release
candidates may contain bugs.
about 30% smaller!

Oct 12 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.