style.visibility即使是隐藏了还是要占用一定的空间,所以你可以试着创建追加结点,比如:
<script language="javascript" >function PvcChange(i)
{
var content = new Array('与a有关的内容','与b有关的内容','与c有关的内容','与d有关的内容','与e有关的内容');
var div = document.createElement("div");
var upnode = document.getElementById("pnode");
upnode.innerHTML = "";
div.innerText = content[parseInt(i)];
upnode.appendChild(div);
}</script>
</head>
<body onload="PvcChange(0);return true;">
<form name="form1" method="post" action="">
<table cellSpacing="4" cellPadding="0" border="0">
<tr>
<td>AAA</td>
<td><input type="text" size="4" name="atmVpi"></td>
</tr>
<tr>
<td>BBB</td>
<td><input type="text" size="4" name="atmVci"></td>
</tr>
</table>
<table width="81%" height="85" border="1">
<tr>
<td><input type="radio" name="pvc" value="1" onClick="PvcChange(0)" checked>
a
<input type="radio" name="pvc" value="2" onClick="PvcChange(1)">
b
<input type="radio" name="pvc" value="3" onClick="PvcChange(2)">
c
<input type="radio" name="pvc" value="4" onClick="PvcChange(3)" >
d
<input type="radio" name="pvc" value="5" onClick="PvcChange(4)">
e</td>
</tr>
<tr>
<td id="pnode">
</td>
</tr>
</table>
<p>
<input type="button" name="apply" value="apply">
</p>
<div id='vlanEnblInfo'></div>
</p></form>
</body>
</html>