I want to hide certain rows of a table depending on what selection the user makes.
Here is my code that works in IE 6, but it doesn't do anything in Netscape 6.
If s == 'SP' then I want to hide some of the rows, if not then I want to show them. The rows each have a unique ID - 'OwnerPct1' etc.
Code:Function swEntityType(s){ var OwnerPct1 = document.getElementById("OwnerPct1"); var OwnerPct2 = document.getElementById("OwnerPct2"); var Owner2 = document.getElementById("Owner2"); If (s == "SP") { var sDisplay = "none"; Owner1Pct.style.display = sDisplay; Owner2Pct.style.display = sDisplay; Owner2.style.display = sDisplay; } Else { var sDisplay = ""; Owner1Pct.style.display = sDisplay; Owner2Pct.style.display = sDisplay; Owner2.style.display = sDisplay; } }




Reply With Quote