下劃線僅使用HTML和CSS,當我使用a
標籤是用前綴它一個_
爲什麼我的鏈接添加在「隨機」位置
我想我已經使用了content
標籤的一些地方,但令我驚訝的是,它堅持在JSFIDDLE
<section>
<h3>Activity</h3>
<a href="#">
<div class="activity">
<div>Some</div>
<div>> 198 days?</div> <!-- why does this render as _> 198 days? -->
<div>Progressing</div>
</div>
</a>
<br />
<a href="#">> does not have underscore despite having > </a>
</section>
CSS
.activity {
background: #3ea18f;
clear: both;
margin-bottom: 2%;
border-radius: 4px;
padding-left: 10%;
}
.activity div {
width: 33%;
display: inline-block;
}
結果
卸下a
標籤可以解決問題,但是,我需要的a
標籤
同樣,除去CSS .activity div
還刪除_
但顯然我需要的風格
同問題依然存在如果我使用<div>> 198 days?</div>
你在使用文字'>'和'<'嗎?嘗試使用http://www.tutorialspoint.com/html5/html5_entities.htm – user993553
@ user993553,我知道這一點,對不起,我沒有說清楚 - 雖然同樣的問題仍然存在 – Dave
這是鏈接文字裝飾,但爲什麼你需要很多html裏面的aa? – user993553