dedecms切换模板css,DEDECMS的模板的css的详细解释 -电脑资料

有的比较菜鸟的站长们,常常看到模板文件的CSS的代码密密麻麻的,就有点头晕!我在网上找到一位热心的站长给出了一份织梦模板的CSS详解,以下就是代码和代码的解释!

/*---------- import ---------*/ //调用外部CSS中调用外部CSS的语法是@import url("file.css");直接插入到CSS文件或之间就可以了,

@import url("layout.css");

@import url("page.css");

/*---------- base ---------*/  //基本样式

*{ //*,通用符

padding:0px; //对像间隔,

margin:0px; //左右边距

}

html{ //所有html均适用此样式

background:#FFF;

}

body{

font:12px Verdana,Arial,Tahoma; //正文字体,字号

}

img{

border:none; //图片,不显示边框

}

a{//超链接

color:#3366CC;

text-decoration:none; //表示没有下划线

}

a:hover{

color:#F33;

text-decoration:underline; //表示有下划线的

}

ul{

list-style.:none;

}

input,select,button{

font:12px Verdana,Arial,Tahoma;

vertical-align:middle; //坚直上居中排列

}

/*---------- stock ---------*/

.center{ //中间主体部分,导航栏处

margin:0px auto;

}

.w960{

width:960px; //中间主体宽度960

position:relative; //它可以随窗口大小变化

}

.mt1{/* ( margin-top * 1 ) */ //样式mt11,距顶端8PX

margin-top:8px;

}

.mt2{/* ( margin-top * 2 ) */

margin-top:16px;

}

.clear{

overflow:hidden; //让浏览器窗口永远不出现滚动条

}

.fs-12{

font-size:12px;

}

.fc-f60{

color:#F60;

}

.fc-f90{

color:#F90;

}

.ipt-txt{

line-height:15px;

padding:4px 5px;

border-width:1px;

border-style.:solid;

border-color:#666 #BBB #BBB #666;

font-size:12px;

margin-right:2px;

}

.btn-1{

width:56px;

height:23px;

border:none;

background:url(../images/btn-bg1.gif) no-repeat; //不平铺,repeat-x为向上平铺

line-height:25px; //行高为

letter-spacing:1px; //文字间隔属性

overflow:hidden;

color:#2F592E;

}

.btn-2{

width:70px;

height:25px;

border:none;

background:url(../images/btn-bg2.gif) left top no-repeat;

line-height:25px;

overflow:hidden;

color:#444;

margin-right:2px;

}

另一份:

.header{

width:100%;

padding-top:16px;

overflow:hidden;

}

.header a{

color:#777;

}

.header a:hover{

color:#390;

text-decoration:none;

}

.header .top{

clear:both;

overflow:hidden;

}

.header .title{

float:left;

padding-left:16px;

}

.header .title h1 a{

width:200px;

height:56px;

display:block;// 可以理解为块,DEDECMS的模板的css的详细解释》(https://www.unjs.com)。把这个区域变成块状。当然你加了宽度和高度效果不明显了。如果去掉宽度和高度试试。再去掉display试试就发现问题了font-size:0px;

text-indent:-200px;

overflow:hidden;

background:url(../images/top-logo.gif) center center no-repeat; //logo大小

}

.header .banner{

width:480px;

height:56px;

float:left;

margin-left:40px;

overflow:hidden;//顶部图片}

.header .banner img{

width:480px;

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值