tab选项卡效果
时间:2010-05-25
来源:互联网
各位大虾看下这种效果,我是做成背景色,但具体实现起来背景有重复
源页面代码:
<div class="TabTitle">
<ul id="myTab1">
<li id="t1" class="active" onclick="nTabs(this,0);"><span class="t1_left"></span><span class="czx_title_1">选项1</span><span class="t1_right"></span></li>
<li id="t2" class="normal" onclick="nTabs(this,1);"><span class="czx_title_1">选项2</span></li>
</ul>
</div>
css页面代码
.nTab{float: left;width:100%;}
.nTab .TabTitle{clear: both;height:22px;width:730px;}
.nTab .TabTitle ul{width:730px;height:22px; }
.nTab .TabTitle li{list-style-type: none; background:#CC3300;text-align:center;margin: 0;}
.active{background:url(../images/b2.jpg) bottom no-repeat; width:133px; display:block; float:left;}
.normal{background:url(../images/a2.jpg) bottom no-repeat; width:133px; display:block;float:left;}
#t1.active{background:url(../images/a1.jpg) bottom no-repeat; width:133px;display:block; float:left; }
#t2.normal{background:url(../images/b1.jpg) bottom no-repeat; width:133px;display:block; float:left;}
两个选项可能实现,多个就出问题了,有何方法解决?
[ 本帖最后由 bailinxin 于 2010-5-25 18:28 编辑 ]
作者: bailinxin 发布时间: 2010-05-25
北京重复,加no-repeat
作者: iaw2001200 发布时间: 2010-05-26
围观
作者: cwq2jxl 发布时间: 2010-05-26
相关阅读 更多
热门阅读
-
office 2019专业增强版最新2021版激活秘钥/序列号/激活码推荐 附激活工具
阅读:74
-
如何安装mysql8.0
阅读:31
-
Word快速设置标题样式步骤详解
阅读:28
-
20+道必知必会的Vue面试题(附答案解析)
阅读:37
-
HTML如何制作表单
阅读:22
-
百词斩可以改天数吗?当然可以,4个步骤轻松修改天数!
阅读:31
-
ET文件格式和XLS格式文件之间如何转化?
阅读:24
-
react和vue的区别及优缺点是什么
阅读:121
-
支付宝人脸识别如何关闭?
阅读:21
-
腾讯微云怎么修改照片或视频备份路径?
阅读:28