网站导航栏下拉菜单偏移问题

sdqingdaolibo 2011-11-01 09:10:27
网站导航栏当电脑分辨率改变时有偏移,这是一个部分的代码,请大家帮忙看看。
<DIV class=menu id=Layer3 onmouseover="this.style.visibility=''"
style="Z-INDEX: 1; LEFT: 345px; VISIBILITY: hidden; WIDTH: 60px; POSITION: absolute; TOP: 139px; HEIGHT: 268px"
onmouseout="this.style.visibility='hidden'">
<TABLE cellSpacing=1 cellPadding=0 width="100%" border=0>
<TBODY>
<TR>
<TD bgColor=#02602c>
<TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>
<TBODY>
<TR>
<TD><IMG height=5 src="" width=1></TD></TR>
<TR>
<TD class=sub_nav_green
onmouseover="this.className='sub_nav_red';this.style.cursor='hand'"
onclick="location.href='newslist1.asp'"
onmouseout="this.className='sub_nav_green'"> -动态</TD></TR>
<TR>
<TD class=nav_gray align=right><IMG
src="index/sub_nav_dot.gif"></TD></TR>
<TR>
<TD class=sub_nav_green
onmouseover="this.className='sub_nav_red';this.style.cursor='hand'"
onclick="location.href='newslist.asp'"
onmouseout="this.className='sub_nav_green'"> -新闻</TD>
</TR>

<TR>
<TR>
<TD class=nav_gray align=right><IMG
src="index/sub_nav_dot.gif"></TD></TR>
<TR>

<TD class=sub_nav_green
onmouseover="this.className='sub_nav_red';this.style.cursor='hand'"
onclick="location.href='newslist2.asp'"
onmouseout="this.className='sub_nav_green'"> -典型</TD>
</TR>

<TD class=nav_gray align=right><IMG
src="index/sub_nav_dot.gif"></TD></TR>
</TABLE></TD></TR></TBODY></TABLE></DIV>
...全文
245 1 打赏 收藏 转发到动态 举报
写回复
用AI写文章
1 条回复
切换为时间正序
请发表友善的回复…
发表回复
叫我梁大侠 2011-11-01
  • 打赏
  • 举报
回复
看你那个DIV的样式就知道问题了

<DIV class=menu id=Layer3 onmouseover="this.style.visibility=''"
style="Z-INDEX: 1; LEFT: 345px; VISIBILITY: hidden; WIDTH: 60px; POSITION: absolute; TOP: 139px; HEIGHT: 268px"

建议用JS获取到客户端的分辨率之后判断top left right的位置大小

28,390

社区成员

发帖
与我相关
我的任务
社区描述
ASP即Active Server Pages,是Microsoft公司开发的服务器端脚本环境。
社区管理员
  • ASP
  • 无·法
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧