【发布时间】:2012-08-20 20:53:30
【问题描述】:
在这个问题positioning text of anchor within a div 并给出了我在这里重复的相同代码:
HTML 标记
<div id="header">
<a href="cattle.html" class="current">Cattle Farms</a>
</div>
CSS 样式
#header a {
width: 100%;
height: 100%;
display: block;
font-size: 25px;
}
回答
div#header a {
width: 100%;
height: 100%;
display: block;
text-indent: 20px;
line-height: 350px;
}
我的问题是为什么 line-height 不能使 a 突破 div
【问题讨论】:
-
@Paul Calabro:也许其他人可以提出更好的见解。
标签: html css text-indent