Metbrötchen
New member
Hi,
wer kann mir sagen, warum der Netscape-Browser hier nicht in dioe Funktion springt?
<script language='JavaScript'>
<!--
function tauschen1()
{
var top=Math.round(Math.random()*600);
var left=Math.round(Math.random()*800);
if(navigator.appName=='Netscape')
{
document.layers['button'].top = top;
document.layers['button'].left = left;
}
if(navigator.appName =='Microsoft Internet Explorer')
{
button.style.top=top;
button.style.left=left;
}
}
//-->
</script>
<html>
<head>
<title>Page</title>
</head>
<body bgcolor="#0000FF">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td>
<DIV ID="button" STYLE="position: absolute; top:100px; left:100px;">
<a href="./"><img src="Nein_Button01.gif" onMouseOver='tauschen1()'></a>
</div>
</td>
<td>
<div id="buttonJa" STYLE="position: absolute; top:100px; left:400px;">
<a href="./"><img src="Ja_Button01.gif" border=0></a>
</div>
</td>
</tr>
</table>
</body>
</html>
Mit dem IE Funktioniert alles SUPER, aber der sch.. Netscape will nicht....
				
			wer kann mir sagen, warum der Netscape-Browser hier nicht in dioe Funktion springt?
<script language='JavaScript'>
<!--
function tauschen1()
{
var top=Math.round(Math.random()*600);
var left=Math.round(Math.random()*800);
if(navigator.appName=='Netscape')
{
document.layers['button'].top = top;
document.layers['button'].left = left;
}
if(navigator.appName =='Microsoft Internet Explorer')
{
button.style.top=top;
button.style.left=left;
}
}
//-->
</script>
<html>
<head>
<title>Page</title>
</head>
<body bgcolor="#0000FF">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td>
<DIV ID="button" STYLE="position: absolute; top:100px; left:100px;">
<a href="./"><img src="Nein_Button01.gif" onMouseOver='tauschen1()'></a>
</div>
</td>
<td>
<div id="buttonJa" STYLE="position: absolute; top:100px; left:400px;">
<a href="./"><img src="Ja_Button01.gif" border=0></a>
</div>
</td>
</tr>
</table>
</body>
</html>
Mit dem IE Funktioniert alles SUPER, aber der sch.. Netscape will nicht....