You are here: irt.org | FAQ | DHTML | Q1420 [ previous next ]
The following has been tested in Netscape Navigator 4, Mozilla, Internet Explorer 4 and Internet Explorer 5:
<script language="JavaScript"><!-- function show(object) { if (document.getElementById && document.getElementById(object) != null) node = document.getElementById(object).style.visibility='visible'; else if (document.layers && document.layers[object] != null) document.layers[object].visibility = 'visible'; else if (document.all) document.all[object].style.visibility = 'visible'; } function hide(object) { if (document.getElementById && document.getElementById(object) != null) node = document.getElementById(object).style.visibility='hidden'; else if (document.layers && document.layers[object] != null) document.layers[object].visibility = 'hidden'; else if (document.all) document.all[object].style.visibility = 'hidden'; } //--></script> <style type="text/css"><!-- .myStyle { position: absolute; visibility: hidden; } //--></style> <a href="javascript:;" onMouseOver="show('myLayer1')" onMouseOut="hide('myLayer1')">a text link</a> <span id="myLayer1" class="myStyle"> <table bgcolor="#ffffcc"><tr><td>This text is initially hidden from view</td></tr></table> </span>