JavaScript Code:
Code:
function toggleLayer(whichLayer) {
if (document.getElementById) {
distal = document.getElementById('distal');
classic = document.getElementById('classic');
}
if (distal.style.display == "none"){
distal.style.display = "block";
classic.style.display = "none";
}
else if (classic.style.display == "none"){
classic.style.display = "block";
distal.style.display = "none";
}
}
function toggleLayer(whichLayer) {
if (document.getElementById) {
distal = document.getElementById('distal');
classic = document.getElementById('classic');
}
if (distal.style.display == "none"){
distal.style.display = "block";
classic.style.display = "none";
}
else if (classic.style.display == "none"){
classic.style.display = "block";
distal.style.display = "none";
}
}
Html:
Code:
<span class="textDropAddCho">Distal: <input name="radio" value="1" type="radio" onClick="toggleLayer('distal');" checked="checked"/>
</span>
<span class="textDropAddCho">Classic:
<input name="radio" value="2" type="radio" onclick="toggleLayer('classic');"/>
<div id="distal></div>
<div id="classic" style="displey:none;"></div>
<span class="textDropAddCho">Distal: <input name="radio" value="1" type="radio" onClick="toggleLayer('distal');" checked="checked"/>
</span>
<span class="textDropAddCho">Classic:
<input name="radio" value="2" type="radio" onclick="toggleLayer('classic');"/>
<div id="distal></div>
<div id="classic" style="displey:none;"></div>