盒模型舉例

sunnylovecmc發表於2009-11-08

 <!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=utf-8" />
<title>無標題文件</title>
<style>
*{
 margin:0px;
 padding:0px;
 border:none;
}

#d{
 background-color:#6FF;
 color:#000;
 border:solid 5px #F00;
 padding:5px;
 margin:5px;
}

#con{
 border:solid 5px #0f0;
 background-color:#FFF;
}
</style>
</head>

<body bgcolor="#CCCCCC">
<div id="con">
<div id="d">AaJj中文</div>
</div>
</body>
</html>

相關文章