CSS处理斜角导航条的一个例子 [源码].txt
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gbk" />
<title>www.zishu.cn</title>
<style>
/*全局处理一下*/
ul{margin:0 0 0 50px;font-size:12px;}
/*tab 基础CSS原形 可扩展*/
.tab li{display:inline;}
.tab a{background: url(http://www.zishu.cn/attachments/month_0708/u2007823223236.gif) no-repeat;}
.tab a:link,.tab a:visited{float:left;background-position:right -226px;text-decoration: none; margin-left:-20px; padding-right:30px;}
.tab a:link span,.tab a:visited span{display:block;background: url(http://www.zishu.cn/attachments/month_0708/u2007823223236.gif) no-repeat left top;padding:5px 15px 2px 15px; color:#000}
.tab a:hover,.tab a:active{background-position:right -264px;}
.tab a:hover span,.tab a:active span{background-position:left -38px;}
.tab .on a:link,.tab .on a:visited{background-position:right -302px;}
.tab .on a span,.tab .on a:link span,.tab .on a:visited span{background: url(http://www.zishu.cn/attachments/month_0708/u2007823223236.gif) no-repeat left -77px;;color:#000; font-weight:bold}
/*有了原形后,可以控制他的其它样子,例如,显示大一点的,只要多加这一行就行了*/
.big li{line-height:2.0; font-size:14px;}
/*这名没有什么用*/
.info{ border:1px solid #FF9900; clear:both; font-size:12px; padding:10px;}
</style>
</head>
<body>
<ul class="tab">
<li class="on"><a href="http://www.kijiji.cn" target="_blank"><span>首 页</span></a></li>
<li ><a href="http://www.kijiji.cn/fabu" target="_blank"><span>发布信息</span></a></li>
<li ><a href="http://www.kijiji.cn/wo" target="_blank"><span>我的客齐集</span></a
相关文档:
基本CSS选择器有标记选择器、类别选择器、ID选择器3种
1。标记选择器
每一种HTML标记的名称都可以作为相应的标记选择器的名称,如h1,p,等等
2。类别选择器
类别选择器的名称可以由用户自定义
格式如下:.class{color:green;font-size:20px;}
3。ID选择 ......
在网页设计中,table用height:100%是可以整屏的,但需要在网页头部增加:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
后就和没 ......
CSS语法 (不区分大小写) JavaScript语法 (区分大小写)
border border
border-bottom &nbs ......
margin-bottom:8px;设置对象下边距的高度
内联对象要使用该属性,必须先设定对象的height或width属性,或者设定position属性为absolute。
padding-top:10px;与上一个标签的距离
padding-left:10px;与左边的间距
检索或设置对象顶边的补丁边距。
内联对象要使用该属性,必须先设定对象的height或width属性,或者设定pos ......