【发布时间】:2010-04-10 04:10:32
【问题描述】:
我正在尝试使用 css 和 html 在 div 容器中插入图像,但它不显示任何图像。
html代码:
<div id="wrapper">
<div id="quoteContainer">
<span class="start_img"></span>
</div>
</div>
css:
#quoteContainer {
color: #898989;
background:#F9F9F9;
border: solid 1px #ddd;
border-radius:10px;
-moz-border-radius: 10px;
-webkit-border-radius: 10px;
box-shadow: 0px 0px 10px #888;
-moz-box-shadow: 0px 0px 10px #888;
-webkit-box-shadow: 0px 0px 10px #888;
margin:65px auto;
padding:15px;
width:500px;
}
.start_img {
background: url(image/img1.png);
border: dotted 2px black;
width:200px;
height:20px;
}
除了img,连边框都不显示。我尝试在 html 中使用<img> 标记将图像插入到 div 中,但这也不起作用。代码有什么问题吗?
【问题讨论】: