原code如下
function show_hide(id) {
if (document.getElementById(id).style.display == 'block')
document.getElementById(id).style.display = 'none';
else if (document.getElementById(id).style.display == 'none')
document.getElementById(id).style.display = 'block';
document.getElementById('opt').value = 0;
}
default
first option
second option
third option
fourth option
show/hide first option
show/hide second option
show/hide third option
show/hide fourth option
(more...)
建议用JS的framework, JQuery, Prototype 都不错