搞不懂的問題
<style type="text/css">
*{margin:0;padding:0}
img{margin:20px 20px;border:1px solid #F00}
.content{border:5px solid #60F;padding:30px 30px;width:700px;}
.book{background:url(../dreamweaver%E7%AB%99%E7%82%B9%E7%AE%A1%E7%90%86/b.jpg) no-repeat #F03;}
</style>
</head>
<body>
<div class="content book">
? ? <img src="../dreamweaver站點管理/01.jpg" width="150" height="100" />?
? ? <img src="../dreamweaver站點管理/02.jpg" width="150" height="100" />?
? ? <img src="../dreamweaver站點管理/03.jpg" width="150" height="100" />?
? ? </div>
? ??
</body>
</html>
為什么我這個代碼的背景顏色只能填一半?可以填慢的時候連左上角的字都被覆蓋了?
2016-05-29
首先不知道你設的背景圖片大小多大,設的是no repeat,的確可能存在撐不滿情況出現。字那個,是你圖片上有字嗎?代碼里面沒看到字啊。
2016-05-24
<style type="text/css">
.content{ border:4px solid #0FF; background:url(file:///D|/Me%20Web/Enterprise/2/images/t_book.gif) no-repeat; padding:36px 14px 15px; width:738px;}
img{ margin:20px 20px; border:1px #333333 solid;}
</style>
</head>
<body>
<div class="content">
<img src="file:///D|/Me Web/Enterprise/2/images/book1.jpg" width="80" height="80" />
<img src="file:///D|/Me Web/Enterprise/2/images/book2.jpg" width="80" height="80" />
<img src="file:///D|/Me Web/Enterprise/2/images/book3.jpg" width="80" height="80" />
<img src="file:///D|/Me Web/Enterprise/2/images/book4.jpg" width="80" height="80" />
<img src="file:///D|/Me Web/Enterprise/2/images/book5.jpg" width="80" height="80" />
</div>
</body>
2016-05-22
你在div后面再加一個包裹層,然后設置居中試一下