div无图片圆角矩形设计

<!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=gb2312" />
<title>无标题文档</title>
</head>
<style type="text/CSS">
.nifty{margin:0;background:#e9e9e9; width:850px;}
p {padding:10px} /*调节div高度的*/
div.rtop {display:block;background:#000;}  /*是圆角矩形背景色*/
div.rtop div {display:block;height:1px;overflow:hidden;background:#e9e9e9}
div.r1{margin:0 5px}
div.r2{margin:0 3px}  /*上右下左*/
div.r3{margin:0 2px}
div.rtop div.r4 {margin:0 1px;height:2px;}
.content{text-align:center; margin:0px; padding:20px 10px; height:250px; font-size:14px;}    /*设置div高度*/
</style>


<body>
<div style="position:absolute; top:200px; left:200px;">
<div id="nifty" class="nifty">
    <div class="rtop">
        <div class="r1"></div>
        <div class="r2"></div>
        <div class="r3"></div>
        <div class="r4"></div>
    </div>
   <p id="content" class="content"> </p>
     
    <div class="rtop">
        <div class="r4"></div>
        <div class="r3"></div>
        <div class="r2"></div>
        <div class="r1"></div>
    </div>
</div>
</div>

 

</body>
</html>

你可能感兴趣的:(div无图片圆角矩形设计)