我想在廣告前創建廣場。像這樣image。我如何使用:在屬性之前創建廣場前的廣場
但我不是成功與span:before
屬性創建此。可以用這個創建嗎?如果是,那麼有人可以告訴我我該怎麼做?
我用簡單的CSS創建了這個。這裏是我的代碼
HTML:
<div id="five_day_table">
<h3>Annual Cleaning Schedule</h3>
<div class="r-cl"><span></span>Forecasted Rain Clean</div>
<div class="m-cl"><span></span>Forecasted Manual Clean</div>
<div class="cm-cl"><span></span>Completed Manual Clean</div>
<div class="d-cl"><span></span>Forecasted Dirty Rain</div>
</div>
和CSS
#five_day_table span {
width: 14px;
height: 14px;
display: block;
float: left;
margin: 1px 3px 0px 0px;
}
.r-cl span
{
background: Blue;
}
.m-cl span
{
background: red;
}
.cm-cl span
{
background: green;
}
.d-cl span
{
background: brown;
}
這裏的工作環節。但我只想使用這個HTML。
<div id="five_day_table">
<h3>Annual Cleaning Schedule</h3>
<span class='one'>Forecasted Rain Clean</span>
<span class='two'>Forecasted Manual Clean</span>
<span class='three'>Completed Manual Clean</span>
<span class='four'>Forecasted Dirty Rain</span>
</div>
這怎麼可能?
不錯的工作..感謝名單 – MKD