想在 html 中使用多个?
Want to use multiple in html?
我有一种情况,我想 space 使用多个 space 排除 html 中的元素。除了使用多个
之外还有其他方法吗?
HTML:
<td width="10%">
<a href=""><i class="glyphicon glyphicon-envelope"></i></a>View
<a href=""><i class="glyphicon glyphicon-link"></i></a>Append
<a href=""><i class="glyphicon glyphicon-trash"></i></a>Delete
</td>
使用 CSS 将 margin
或 padding
更改为 space 您的元素通常是公认的答案。
您也可以疯狂使用 position: absolute
或 postion: relative
和 space 元素,方法是使用 top
和 left
属性。
我自己想通了:
这可以通过以下方式实现,具体取决于您想要多少 space:
- single space
  - thin space
  - en space(half the point size of the font)
  - em space(point size of the font)
参考:http://www.w3.org/MarkUp/html3/specialchars.html
这是我所做的:
<td width="10%">
<a href=""><i class="glyphicon glyphicon-envelope"></i></a>View 
<a href=""><i class="glyphicon glyphicon-link"></i></a>Append 
<a href=""><i class="glyphicon glyphicon-trash"></i></a>Delete
</td>
希望这对您有所帮助。
没办法space。你应该更多,我之前研究过,我没有找到任何其他方法。只是,如果你想把 space 用于所有行,请使用 br.
你可以把它放在下面:-
<div class="space_lg"> </div>
css
.space_lg
{
width:100px;
}
如果您想要始终较大的 space,您可以使用 word-spacing
:
p:first-of-type {
word-spacing: 2em;
}
<p>Some text that you want spaced</p>
<p>Some text with regular spacing</p>
将 span
标签与 display:inline-block
一起使用,并向其添加 width
。
我有一种情况,我想 space 使用多个 space 排除 html 中的元素。除了使用多个
之外还有其他方法吗?
HTML:
<td width="10%">
<a href=""><i class="glyphicon glyphicon-envelope"></i></a>View
<a href=""><i class="glyphicon glyphicon-link"></i></a>Append
<a href=""><i class="glyphicon glyphicon-trash"></i></a>Delete
</td>
使用 CSS 将 margin
或 padding
更改为 space 您的元素通常是公认的答案。
您也可以疯狂使用 position: absolute
或 postion: relative
和 space 元素,方法是使用 top
和 left
属性。
我自己想通了: 这可以通过以下方式实现,具体取决于您想要多少 space:
- single space
  - thin space
  - en space(half the point size of the font)
  - em space(point size of the font)
参考:http://www.w3.org/MarkUp/html3/specialchars.html
这是我所做的:
<td width="10%">
<a href=""><i class="glyphicon glyphicon-envelope"></i></a>View 
<a href=""><i class="glyphicon glyphicon-link"></i></a>Append 
<a href=""><i class="glyphicon glyphicon-trash"></i></a>Delete
</td>
希望这对您有所帮助。
没办法space。你应该更多,我之前研究过,我没有找到任何其他方法。只是,如果你想把 space 用于所有行,请使用 br.
你可以把它放在下面:-
<div class="space_lg"> </div>
css
.space_lg
{
width:100px;
}
如果您想要始终较大的 space,您可以使用 word-spacing
:
p:first-of-type {
word-spacing: 2em;
}
<p>Some text that you want spaced</p>
<p>Some text with regular spacing</p>
将 span
标签与 display:inline-block
一起使用,并向其添加 width
。