1、用css实现段落前面缩进两个字

   text-indent: 2em; /*em是相对单位,2em即现在一个字大小的两倍*/

2、用css实现水平虚线的两种方法

   <hr size="1" noshade="noshade" style="border:1px #cccccc dotted;"/>

   <div style="border-top:1px dashed #ccccccc;height:1px;overflow:hidden;"></div>

3、css简单重叠线效果

    样式*{padding:0;margin:0;}

         .line{width:100%;height:30px;line-height:30px;border-bottom:2px grey solid;}

         h3{width:30%;height:30px;line-height:30px;border-bottom:2px green solid;display:inline-block;*zoom:1;*display:inline;margin-bottom:-2px;}

 <div class="line">

   <h3>天之蓝,梦之绿</h3>

</div>

posted on 2015-04-28 10:51  残狼独行  阅读(169)  评论(0编辑  收藏  举报