Thank you very much, Robert!!
You gave me the clue of it all!!
The only thing Netscape needs is to have the display property somewhat initialized before attempting to set it.
I have changed the code and now it works fine for both IE6 and NS7 browsers.
I think this little piece of code may be very useful.
Here is the definitive code:
<HTML>
<HEAD>
<TITLE>DOM :: show/hide rows in a table</TITLE>
</HEAD>
<style type="text/css">
<!--
.block {
display: inline;
}
-->
</style>
<script language="JavaScript">
function toggle(){
var theTable = (document.getElementById('myTABLE'));
var theTB = theTable.tBodies.item(0);
var theTR = theTB.rows.item(1);
if ((theTR.style.display=="")||(theTR.style.display== "inline"))
theTR.style.display="none";
else
theTR.style.display="inline";
}
</script>
<BODY>
<table id="myTABLE" border="1" width="100" align="center" cellpadding="0" cellspacing="0">
<tr id="TR1" class="block">
<td width="50" id="TD11">1.1</td>
<td width="50" id="TD12">1.2</td>
</tr>
<tr id="TR2" class="block">
<td width="50" id="TD21">2.1</td>
<td width="50" id="TD22">2.2</td>
</tr>
<tr id="TR3" class="block">
<td width="50" id="TD31">3.1</td>
<td width="50" id="TD32">3.2</td>
</tr>
</table>
<br><br>
<center><a href="javascript
:toggle();">show/hide</a></center>
</BODY>
</HTML>
and if you want to see it running just click
http://www.oranginalab.com/p2p
Thanks a lot, Robert.
Tomàs Jiménez
OranginaLab