Discuz!官方免费开源建站系统

 找回密码
 立即注册
搜索

[求助] 添加导航代码后出错,请懂代码的老大进来看看!

[复制链接]
明天过后 发表于 2011-3-8 09:54:50 | 显示全部楼层 |阅读模式
大家看看这个代码什么地方出错了导致头部出错  如图

出错图: 出错.jpg

正常图: 正常.jpg

导致会员名一栏加长了!
我添加的是网易的导航代码
代码:
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />
  5. <meta name="robots" content="index, follow" />
  6. <meta name="googlebot" content="index, follow" />
  7. <link rel="apple-touch-icon-precomposed" href="http://img1.cache.netease.com/www/logo/logo-ipad-icon.png" >
  8. <script charset="gb2312" src="http://img3.cache.netease.com/cnews/js/ntes_jslib_1.x.js" language="javascript" type="text/javascript"></script>
  9. <link id="setSkin" type="text/css" rel="stylesheet" href="http://img2.cache.netease.com/www/v2011/css/theme_blue1227.css" />
  10. <style type="text/css">
  11. html {overflow-y:scroll;}
  12. body {margin:0; padding:0px 0 0; font:12px "\5B8B\4F53",san-serif;background:#ffffff;}
  13. div,dl,dt,dd,ul,ol,li,h1,h2,h3,h4,h5,h6,pre,form,fieldset,input,textarea,blockquote,p{padding:0; margin:0;}
  14. table,td,tr,th{font-size:12px;}
  15. li{list-style-type:none;}
  16. img{vertical-align:top;border:0;}
  17. ol,ul {list-style:none;}
  18. h1,h2,h3,h4,h5,h6 {font-size:12px; font-weight:normal;}
  19. address,cite,code,em,th {font-weight:normal; font-style:normal;}
  20. .ntes-passport a {color:#727171;}
  21. .ntes-passport a:hover {color:#ba2636;}
  22. .fB{font-weight:bold;}
  23. .f12px{font-size:10px;}
  24. .f14px{font-size:10px;}
  25. .left{float:left;}
  26. .right{float:right;}
  27. .I_V_ {background:url(http://img1.cache.netease.com/img09/icon/icon.png) left center no-repeat; padding-left:18px;}
  28. .I_M_ {background:url(http://img1.cache.netease.com/img09/icon/icon.png) -457px center no-repeat; padding-left:18px;}
  29. .I_cleardot_ {background:#fff; padding:0 0 0 10px; margin:0 6px 0 -10px; float:left; vertical-align:middle; cursor:pointer;}
  30. .I_cleardot_:hover {text-decoration:underline;}
  31. .foot{margin:0 auto; width:960px; line-height:21px; clear:both; color:#4d4d4d;}
  32. .foot .text{padding:4px 0 5px; border-bottom:1px solid #4d4d4d; margin:0 0 5px;}
  33. .foot a,.foot a:visited{color:#4d4d4d;}
  34. .foot a:hover {color:#ba2636;}
  35. /* link css */
  36. a {color:#2b2b2b; text-decoration:none;}
  37. a:visited {text-decoration:none;}
  38. a:hover {color:#ba2636;text-decoration:underline;}
  39. a:active {color:#ba2636;}
  40. .sub-list a,.sub-list a:visited {color:#585858;}
  41. .cDGray,.cDGray:visited,.cDGray a{color:#727171;}
  42. .cBlue,.cBlue:visited,.cBlue a{color:#1E50A2;}
  43. .cDRed,.cDRed:visited,.cDRed a{color:#ba2636;}
  44. .cRed {color:#ff0000;}
  45. .tab-u a:hover,.cRed a:hover,a.cRed:hover,.sub-list a:hover,.cBlue a:hover,a.cBlue:hover,.cDRed a:hover,a.cDRed:hover,.cGray a:hover,a.cGray:hover,.cDGray a:hover,a.cDGray:hover,.cWhite a:hover,a.cWhite:hover,.cBlack a:hover,a.cBlack:hover,.cGreen a:hover,a.cGreen:hover,.cYellow a:hover,a.cYellow:hover{color:#ba2636;}

  46. /* ntes snippet */
  47. h1 {display:none;}
  48. .logo {float:left; _display:inline; margin: 19px 7px 0 16px;}
  49. .channel {float:right; height:80px; overflow:hidden;}
  50. .channel-col {float:left; _display:inline; margin:10px 0 0 -1px; padding:0 0 0 16px; line-height:20px; border-left:1px solid #dcdddd;}
  51. .channel-col a {float:left; margin:0 6px 0 0; width:24px;}
  52. .channel-col .w3 {float:left; margin:0 6px 0 0; width:36px;}
  53. .channel-col strong {float:left; margin-right:6px;}
  54. .channel-col strong a {width:26px;}
  55. .col-w .nowrap {float:left; width:138px;}
  56. .col .nowrap {float:left; width:108px;}
  57. .col-w3 .nowrap {float:left; width:120px;}





  58. </style>
  59. </head>

  60. <!-- 背景广告 -->
  61. <div class="header">
  62. <h1>网易</h1>
  63. <div class="logo">
  64. <a href="http://www.163.com/"><img src="http://img3.cache.netease.com/www/logo/logo_png.png" alt="网易" title="网易" border="0" height="37" width="118" /></a>
  65. </div>
  66. <div class="channel">
  67. <div class="channel-col col-w">
  68. <span class="nowrap"><strong><a href="http://news.163.com/">新闻</a></strong> <a href="http://war.news.163.com/">军事</a> <a href="http://news.163.com/review/">评论</a> <a href="http://news.163.com/photo/">图片</a>
  69. <strong><a href="http://sports.163.com/">体育</a></strong> <a href="http://sports.163.com/nba/">NBA</a> <a href="http://cbachina.163.com/">CBA</a> <a href="http://sports.163.com/yc/">英超</a>
  70. <strong><a href="http://ent.163.com/">娱乐</a></strong> <a href="http://ent.163.com/movie/">电影</a> <a href="http://ent.163.com/tv/">电视</a> <a href="http://ent.163.com/music/">音乐</a></span>
  71. </div>
  72. <div class="channel-col col-w">
  73. <span class="nowrap">
  74. <strong><a href="http://money.163.com/">财经</a></strong> <a href="http://money.163.com/stock/">股票</a> <a href="http://money.163.com/fund/">基金</a> <a href="http://biz.163.com/">商业</a>
  75. <strong><a href="http://v.163.com/">视频</a></strong> <a href="http://v.163.com/nv/">网视</a> <a href="http://v.163.com/doc/">纪实</a> <a href="http://v.163.com/fashion/">风尚</a>
  76. <strong><a href="http://lady.163.com/">女人</a></strong> <a href="http://fashion.163.com/">时尚</a> <a href="http://lady.163.com/beauty/">美容</a> <a href="http://lady.163.com/sense/">情爱</a>
  77. </span>
  78. </div>
  79. <div class="channel-col col-w3">
  80. <span class="nowrap">
  81. <strong><a href="http://tech.163.com/">科技</a></strong> <a href="http://money.163.com/hkstock/">港股</a> <a href="http://tech.163.com/cnstock/" class="w3">概念股</a>
  82. <strong><a href="http://mobile.163.com/">手机</a></strong> <a href="http://tech.163.com/3G/">3G</a> <a href="http://product.tech.163.com/mobile/" class="w3">手机库</a>
  83. <strong><a href="http://digi.163.com/">数码</a></strong> <a href="http://hea.163.com/">家电</a> <a href="http://tech.163.com/digi/nb/" class="w3">笔记本</a>
  84. </span>
  85. </div>
  86. <div class="channel-col col">
  87. <span class="nowrap">
  88. <strong><a href="http://auto.163.com/">汽车</a></strong> <a href="http://auto.163.com/buy/">购车</a> <a href="http://product.auto.163.com/">搜车</a>
  89. <strong><a href="http://travel.163.com/">旅游</a></strong> <a href="http://discovery.163.com/">探索</a> <a href="http://sports.163.com/lottery/">彩票</a>
  90. <strong><a href="http://house.163.com/" id="houseUrl">房产</a></strong> <a href="http://home.163.com/">家居</a> <a href="http://xf.house.163.com/gz/">买房</a>
  91. </span>
  92. </div>
  93. <div class="channel-col col">
  94. <span class="nowrap">
  95. <strong><a href="http://bbs.163.com/">论坛</a></strong> <a href="http://bbs.163.com/special/00153AU9/bbsrank.html">热贴</a> <a href="http://photo.163.com/">摄影</a>
  96. <strong><a href="http://blog.163.com/?fromNavigation">博客</a></strong> <a href="http://blog.163.com/blogger.html">名博</a> <a href="http://edu.163.com/">教育</a>
  97. <strong><a href="http://game.163.com/">游戏</a></strong> <a href="http://wan.163.com/">页游</a> <a href="http://book.163.com/">读书</a>
  98. </span>
  99. </div>
  100. <div class="channel-col col">
  101. <span class="nowrap">
  102. <strong><a href="http://t.163.com/" style="color:#ba2636;">微博</a></strong> <a href="http://t.163.com/rank/daren">人物</a> <a href="http://t.163.com/rank">热点</a>
  103. <strong><a href="http://fushi.163.com/">服饰</a></strong> <a href="http://baby.163.com/">亲子</a> <a href="http://gongyi.163.com/">公益</a>
  104. <strong><a href="http://m.163.com/">应用</a></strong> <a href="http://shop.163.com/">商城</a> <a href="http://media.163.com/">传媒</a>
  105. </span>
  106. </div>
  107. </div>
复制代码

回复

使用道具 举报

 楼主| 明天过后 发表于 2011-3-8 09:59:19 | 显示全部楼层
没有懂得吗?
回复

使用道具 举报

deviljing 发表于 2011-3-8 10:29:06 | 显示全部楼层
不懂的别乱加CSS代码, 里面有很多可能冲突的你都加上去了
回复

使用道具 举报

 楼主| 明天过后 发表于 2011-3-8 10:40:48 | 显示全部楼层
回复 deviljing 的帖子

那怎么才能做成那个样子呢?大哥你会吗?帮写个呗
回复

使用道具 举报

deviljing 发表于 2011-3-8 11:36:28 | 显示全部楼层
哪个样子?  图片能看什么?
你怎么添的我都不知道
回复

使用道具 举报

 楼主| 明天过后 发表于 2011-3-8 14:07:06 | 显示全部楼层
回复 deviljing 的帖子

就是网易首页的 导航
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

手机版|小黑屋|Discuz! 官方站 ( 皖ICP备16010102号 )star

GMT+8, 2025-9-8 20:37 , Processed in 0.133368 second(s), 17 queries , Gzip On.

Powered by Discuz! X3.4

Copyright © 2001-2023, Tencent Cloud.

快速回复 返回顶部 返回列表