<select nane="selectAB" onchange="redirect(this.options.selectedIndex)">var tmp1=document.selectAB function redirect(x) { for (j=document.roundForm.searchC2.options.length-1;j>0;j--) tmp1.options[j]=null;
for (k=0;k<array1[x].length;k++) { tmp1.options[k]=new Option(array1[x][k].text,array1[x][k].value); } tmp1.options[0].selected=true; }
function redirect(x)
{
for (j=document.roundForm.searchC2.options.length-1;j>0;j--)
tmp1.options[j]=null;
for (k=0;k<array1[x].length;k++)
{
tmp1.options[k]=new Option(array1[x][k].text,array1[x][k].value);
}
tmp1.options[0].selected=true;
}
不过你也可以做两个block然后显示其中的一个应该也就行了
请问应怎样做?
if(flag1.equals("true")) 显示table A;
if(flag2.equals("true")) 显示table B;select 用onchange来控制标志项.