Habe folgendes probiert:
<script language="JavaScript">
<!--
<!--
ns4 = (document.layers)? true:false
ie4 = (document.all)? true:false
v6 = (document.getElementById)? true:false
function showlayer(i)
{
if (ns4) document.layers[i].visibility = "show"
else if (v6) document.getElementById(i).style.visibility = "visible";
else if (ie4) document.all[i].style.visibility = "visible"
}
function hidelayer(i)
{
if (ns4) document.layers[i].visibility = "hide"
else if (v6) document.getElementById(i).style.visibility = "hidden";
else if (ie4) document.all[i].style.visibility = "hidden"
}
/*
function MM_callJS(jsStr) { //v2.0
return eval(jsStr)
}*/
//-->
</SCRIPT>
</head>
<body bgcolor="#FFFFFF" text="#000000" >
<STYLE Type=text/css>
.text1 { font-size:16px; font-family:Arial; position:static; visibility:visible }
.t2 { font-size:0px; font-family:Arial; position:static; visibility:hidden }
</STYLE>
<div Class=text1>
<a href=http://www.ich.de onmouseover="on(t1);" onmouseout="off(t1);">der</a></div> <!--Fehlermeldung Objekt erwartet -->
<div ID=t1> test<br>test<br>test</div>
<div ID=pop1 Class=text1>
<a href=http://www.ich.de onmouseover="on(t2);" onmouseout="off(t2);">der</a></div> <!--Fehlermeldung Objekt erwartet -->
<div ID=t2> test<br>test<br>test</div>
und bekomme die zwei Fehlermeldungen Objekt erwartet (s. Skript)
Aber das nächste hat auch funktioniert, wenn auch ohne dynamischen Aufruf:
<script language="JavaScript">
<!--
function on()
{
pop2.style.visibility = "visible"; //IE
pop2.style.fontSize = "12";
}
/*
function on()
{
pop2.style.visibility = "show"; //NN
}
*/
function off()
{
pop2.style.visibility = "hidden"; //IE
pop2.style.fontSize = "0";
}
/*
function off()
{
pop2.style.visibility = "hide"; //NN
}
*/
function MM_callJS(jsStr) { //v2.0
return eval(jsStr)
}
//-->
</SCRIPT>
</head>
<body bgcolor="#FFFFFF" text="#000000" onLoad="MM_callJS('off()')">
<STYLE Type=text/css>
.text1 { font-size:16px; font-family:Arial; position:static; visibility:visible }
.text2 { font-size:0px; font-family:Arial; position:static; visibility:hidden }
</STYLE>
<div Class=text1>
<a href=http://www.ich.de onmouseover="on()" onmouseout="off()">der</a></div>
<div ID=pop2> test<br>test<br>test</div>
<div ID=pop1 Class=text1>
<a href=http://www.ich.de onmouseover="on()" onmouseout="off()">der</a></div>