Hellow!
I have script from experts-exchange:
<script type="text/javascript">
var prevSelect=0;
function showDivSelect(divID) {
if(document.getElementById
(divID))
{
if( prevSelect && prevSelect != divID)
toggle(prevSelect);
document.getElementById(di
vID).style
.display = 'block';
prevSelect = divID;
}
}
function toggle(divID) {
document.getElementById(di
vID).style
.display = (document.getElementById(d
ivID).styl
e.display=
='none'?'b
lock':"non
e");
}
</script>
<table width="500" ><tr><td valign="top" width="250"><input type="hidden" name="advanced_payments" value="1" style="width: 20px" onClick="toggle('a')">
<div id="a">
<select style="border:none; width:150px; " id="" size="20" name="advanced_payment_typ
e" onchange="showDivSelect(th
is.value);
">
<option value="1">option1</option>
<option value="2">option2</option>
<option value="3">option3</option>
</select>
</td><td width="250" valign="top">
<div id="1" style="display:none">
<div id="2" style="display:none">
<div id="3" style="display:none">
</div>
</div>
Script works fine.. but I need something other.. not listobx but simple <a href="#" onclick="changeDIV">
cam somebody HELP me?!
Tnx..
P.S. sorry for my English!
Start Free Trial