【发布时间】:2014-05-16 22:59:24
【问题描述】:
我怎样才能让三个 div 看起来像下面显示的那样,只有 HTML 和 CSS?是否可以以使底部文本保持在最长文本下方的方式对齐它们?
<html>
<div id=1>
Short text
Bottom text?
</div>
<div id=2>
Long text
Bottom text?
</div>
<div id=3>
Not so long text
Bottom text?
</div>
</html>
【问题讨论】:
-
id="3"是正确的语法,另外,避免使用数字作为 id -
我知道,只是一个快速的帖子;)
-
@Haidy 编辑了我的答案...
标签: html css css-position text-alignment