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 gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Problem with IE6 and WinXP

Status
Not open for further replies.

kippie

Technical User
Nov 8, 2001
158
A trial page of my website works fine in IE5.5 but gives problems with IE6 (and WindowsXP on my system). When using the menu an image swaps in the left window and a text in the right. With IE 5.5 the swapping goes smootly as well as with IE6 and Win98 but which IE6 and WinXP there are gaps between each swapping so you see each time the backgroundimage. In the final website this will be a bigger problem so I would like to solve it. Can anyone help?

This is the address:
And this is the code:
<html>
<head>

<script language=&quot;JavaScript&quot;><!--
var isIE=document.all?true:false;
var isDOM=document.getElementById?true:false;
var isNS4=document.layers?true:false;

//this function preloads the images for the image frame and the backgrounds of the textframe:
function getImages() {
bg4 = new Image();
bg4.src = &quot;bgMidnight.gif&quot;;
bg41 = new Image();
bg41.src = &quot;bgGoldenrod.gif&quot;;
bg50 = new Image();
bg50.src = &quot;bgKhaki.gif&quot;;
bg51 = new Image();
bg51.src = &quot;bgRoyalBlue.gif&quot;;
alt10 = new Image();
alt10.src = &quot;WZWmanopschommel2.jpg&quot;;
alt20 = new Image();
alt20.src = &quot;CQkolk2.jpg&quot;;
alt30 = new Image();
alt30.src = &quot;CQpuzzle2.jpg&quot;;
alt40 = new Image();
alt40.src = &quot;EQmanmetkinderwagen2.jpg&quot;;
}
// -->
</script>
<script language=&quot;JavaScript&quot;><!--
//These are the texts to appear in the textframe
var Home = '<div class=&quot;infohead&quot;>Dit is ExperienceTraining<\/div>'
var WZWmsg0 = '<div class=&quot;infohead&quot;>Wie zijn wij?<\/div>'
var CQmsg0 = '<div class=&quot;headwhite&quot;>Creatieve Intelligentie (CQ)<\/div>'
var EQmsg0 = '<div class=&quot;headwhite&quot;>Emotionele Intelligentie<\/div>'

//This is the function to change text on a changing background in the textframe:
function htmlChange(id,message, bg){
d=document;
re=d.all?d.all[id]:d.getElementById(id);
re.innerHTML=message;
re.style.background = &quot;url(&quot;+bg+&quot;)&quot;;
}

//This is the function which changes images in the imageframe:
function rewriteImg(id,imgName){
d=document;
re=d.all?d.all[id]:d.getElementById(id);
//re.innerHTML=&quot;<img src='&quot;+eval(imgName + &quot;.src&quot;)+&quot;'>&quot;;
re.innerHTML=&quot;<img src='&quot;+eval(imgName + &quot;.src&quot;)+&quot;' height='100%' width='100%'>&quot;;
}
// -->
</script>

<style type=&quot;text/css&quot;><!--
.headwhite { color: #ffffff; font-weight: 700; font-size: 17px; font-family: Arial; text-align: left; width: 100% }
.infohead { color: #191970; font-weight: 700; font-size: 17px; font-family: Arial; text-align: left; width: 100% }

A.top:link { color: white; font-weight: bold; font-family: Arial; font-size: 13px; text-decoration: none}
A.top:visited { color: white; font-weight: bold; font-family: Arial; font-size: 13px; text-decoration: none}
A.top:hover { color: #4169E1; font-weight: bold; font-family: Arial; font-size: 13px; text-decoration: none }
A.top:active { color: lightskyblue; font-weight: bold; font-family: Arial; font-size: 13px; text-decoration: none }
</style>
</head>

<body background=&quot;wereldatlas4.jpg&quot; onload=&quot;getImages()&quot;>
<table border=&quot;0&quot; bordercolor=&quot;red&quot; width=&quot;600&quot; height=&quot;325&quot; cellpadding=&quot;0&quot; cellspacing=&quot;0&quot;>
<tr height=&quot;25&quot;>
<td id=&quot;headmenu&quot; colspan=&quot;2&quot; height=&quot;25&quot;><a href=&quot;#&quot; class=&quot;top&quot; onclick=&quot;htmlChange('textframe',Home,'bgRoyalBlue.gif'); rewriteImg('imageframe','alt10');&quot;>Home</a><img src=&quot;dot.gif&quot; width=&quot;25&quot; height=&quot;1&quot;><a href=&quot;#&quot; class=&quot;top&quot; onclick=&quot;htmlChange('textframe',WZWmsg0,'bgKhaki.gif'); rewriteImg('imageframe','alt20');&quot;>Wie zijn wij?</a><img src=&quot;dot.gif&quot; width=&quot;25&quot; height=&quot;1&quot;><a href=&quot;#&quot; class=&quot;top&quot; onclick=&quot;htmlChange('textframe',CQmsg0,'bgGoldenrod.gif'); rewriteImg('imageframe','alt30');&quot;>CQ</a><img src=&quot;dot.gif&quot; width=&quot;25&quot; height=&quot;1&quot;><a href=&quot;#&quot; class=&quot;top&quot; onclick=&quot;rewriteImg('imageframe','alt40'); htmlChange('textframe',EQmsg0,'bgMidnightBlue.gif');&quot;>EQ</a></td>
</tr>
<tr height=&quot;300&quot;>
<td id=&quot;imageframe&quot; width=&quot;220&quot; height=&quot;300&quot;><img src=&quot;WZWmanopschommel2.jpg&quot; height=&quot;100%&quot; width=&quot;100%&quot;></td>
<td id=&quot;textframe&quot; bgcolor=&quot;#4169E1&quot; width=&quot;380&quot; height=&quot;300&quot;>Dit is ExperienceTraining</td>
</tr>
</table>
</body>
</html>

Kippie
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top