不好意思,兄弟,我忘了加个函数showtb。把下面代码加到javascript里面就可以了:
function showtb(tbnum){whichEl = eval("tbtype" + tbnum);if (whichEl.style.display == "none"
{eval("tbtype" + tbnum + ".style.display=\"\";"
;}else{eval("tbtype" + tbnum + ".style.display=\"none\";"
;}}
完整代码为:
<script>
function zk(){
tbtype1.style.display = "";
tbtype2.style.display = "";
tbtype3.style.display = "";
tbtype4.style.display = "";
tbtype5.style.display = "";
}
function ss()
{
tbtype1.style.display = "none";
tbtype2.style.display = "none";
tbtype3.style.display = "none";
tbtype4.style.display = "none";
tbtype5.style.display = "none";
}
function showtb(tbnum){whichEl = eval("tbtype" + tbnum);if (whichEl.style.display == "none"
{eval("tbtype" + tbnum + ".style.display=\"\";"
;}else{eval("tbtype" + tbnum + ".style.display=\"none\";"
;}}
</script>
<table rules='none' border="0" cellpadding="0" cellspacing="0" style="border-collapse: collapse" width="183" bgcolor="#749AEC" height="924">
<tr>
<td bgcolor="#749AEC" valign="top">
<div align="center">
<table cellpadding="0" style="border-collapse: collapse" width="145" bgcolor="#749AEC">
<tr>
<td bgcolor="#749AEC" valign="top">
<table border="0" cellpadding="0" cellspacing="0" style="border-collapse: collapse" id="table1">
<tr style="CURSOR: hand" onclick=showtb(1) class=td2>
<td width="150" height="25" align="center">
<p align="left">爱普生服务</td>
</tr>
<tr id=tbtype1 style='display:none'>
<td bgcolor="#cad6eb" width="150" valign="top">
<p style="margin: 4; ">
<a href="#">公司简介</a><br>
<a href="#">服务理念</a><br>
<a href="#">环境理念</a><br>
<a href="#">联系通道</a></p></td>
</tr>
<tr style="CURSOR: hand" onclick=showtb(2) class=td2>
<td height="1" align="center"></td>
</tr>
<tr style="CURSOR: hand" onclick=showtb(2) class=td2>
<td height="25" align="center">
<p align="left">服务网络</td>
</tr>
<tr id=tbtype2 style='display:none'>
<td bgcolor="#cad6eb"><p style="margin: 4; ">
<a href="#">服务网络介绍</a><br>
<a href="#">服务网络介绍</a><br>
<a href="#">加入服务网</a></p></td>
</tr>
<tr style="CURSOR: hand" onclick=showtb(3) class=td2>
<td height="1" align="center" height="25">
</td>
</tr>
<tr style="CURSOR: hand" onclick=showtb(3) class=td2>
<td align="center" height="25">
<p align="left">服务项目</td>
</tr>
<tr id=tbtype3 style='display:none'>
<td bgcolor="#cad6eb"><p style="margin: 4; ">
<a href="#">标准服务</a><br>
<a href="adminright1.asp?action=changepwd">特色服务</a><br>
<font color="#3366cc"><a href="#">客服中心</a></font><br>
<a href="#">耗材信息</a><br>
<a href="#">产品使用常识</a></p></td>
</tr>
<tr>
<td height="1" align="center"></td>
</tr>
<tr style="CURSOR: hand" onclick=showtb(4) class=td2>
<td align="center" height="25">
<p align="left">服务政策</td>
</tr>
<tr id=tbtype4 style='display:none'>
<td height="67" bgcolor="#cad6eb"><p style="margin: 4; ">
<a href="#">保修信息</a><br>
<a href="#">三包服务承诺</a><br>
<a href="#">维修指南</a></p></td>
</tr>
<tr>
<td height="1" align="center"></td>
</tr>
<tr style="CURSOR: hand" onclick=showtb(5) class=td2>
<td align="center" height="28">
<p align="left">新闻看台</td>
</tr>
<tr id=tbtype5 style='display:none' bgcolor="#cad6eb">
<td><p style="margin: 4; ">
<a href="#">新闻快报</a><br>
<a href="#">媒体转载</a></p></td>
</tr>
<tr style="CURSOR: hand" onclick=showtb(6) class=td2>
<td height="25">
<a href="#"><font color="#3366cc">返回首页</font></a></td>
</tr>
<tr id=tbtype6 style='display:none' bgcolor="#cad6eb">
<td height="25" border="1" bgcolor="#cad6eb">
<br> <a href="#"><font color="#3366cc">返回首页</font></a></td>
</tr>
</table>
</td>
</tr>
</table>