在HTML中是否还有其他半空格,em-space,en-spaces等空白代码,如& nbsp? [英] Are there other whitespace codes like &nbsp for half-spaces, em-spaces, en-spaces etc useful in HTML?
问题描述
想知道HTML新闻稿中是否有其他代码可以使用.
Wondering if there are other codes available to use in an HTML newsletter.
我会使用单元格填充或边距,但是我对HTML/CSS还是陌生的,我找不到能够同时影响主标题行和其下的副标题的更改.作为电子邮件,我很犹豫如何使用CSS来获得它-因为我不知道哪种电子邮件客户端不喜欢CSS而不是内联标记.
I would use cell padding or margins but I'm new to this HTML/CSS thing and I can't find a change that does effect both the Main Title line and the sub-head under it. Being an email I'm hesitant to go mucking around with the CSS to get it just so — since I don't know what email clients don't like in the way of CSS as opposed to inline markup.
对于上下文,我使用的模板是Mailchimp片段中的静音"主题:
For context the template I'm using is Mute theme from Mailchimp snip:
<!-- language: lang-html -->
<table cellspacing="0" cellpadding="0" border="0" align="center" width="626">
<tbody>
<tr>
<td valign="middle" bgcolor="#546781" height="97" background="images/header-bg.jpg" style="vertical-align: middle;">
<table cellspacing="0" cellpadding="0" border="0" align="center" width="555" height="97">
<tbody>
<tr>
<td valign="middle" width="160" style="vertical-align:middle; text-align: left;">
<img width="70" height="70" src="http://dl.dropbox.com/…….png" style="margin:0; margin-top: 4px; display: block;" alt="" />
</td>
<td valign="middle" style="vertical-align: middle; text-align: left;">
<h1 class="title" style="margin:0; padding:0; font-size:30px; font-weight: normal; color: #192c45 !important;">
<singleline label="Title"><span>Title of Report</span></singleline>
</h1>
<h1 class="title" style="margin:0; padding:0; font-size:15px; font-weight: normal; color: #192c45 !important;">
<singleline label="Title"><span>Small Subhead</span></singleline>
</h1>
</td>
<td width="55" valign="middle" style="vertical-align:middle; text-align: center;">
<h2 class="date" style="margin:0; padding:0; font-size:13px; font-weight: normal; color: #192c45 !important; text-transform: uppercase; font-weight: bold; line-height:1;">
<currentmonthname />December
</h2>
<h2 class="date" style="margin:0; padding:0; font-size:23px; font-weight: normal; color: #192c45 !important; font-weight: bold;">
<currentyear />2011
</h2>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
可以在此处
推荐答案
是的,很多.
包括但不限于:
- 不间断空格:
 
或
- 狭窄的不间断空格:
 
(没有可用的字符引用) - en space:
 
或 
- em空间:
 
或 
- 每em 3个空间:
 
或 
- 每码位数4个空间:
 
或 
- 每em 6个空格:
 
(没有可用的字符引用) - 图空间:
 
或 
- 标点空间:
 
或 
- 稀薄空间:
 
或 
- 头发空间:
 
或 
- non breaking space :
 
or
- narrow no-break space :
 
(no character reference available) - en space :
 
or 
- em space :
 
or 
- 3-per-em space :
 
or 
- 4-per-em space :
 
or 
- 6-per-em space :
 
(no character reference available) - figure space :
 
or 
- punctuation space :
 
or 
- thin space :
 
or 
- hair space :
 
or 
span{background-color: red;}
<table>
<tr><td>non breaking space:</td><td> <span> </span> or <span> </span></td></tr>
<tr><td>narrow no-break space:</td><td> <span> </span></td></tr>
<tr><td>en space:</td><td> <span> </span> or <span> </span></td></tr>
<tr><td>em space:</td><td> <span> </span> or <span> </span></td></tr>
<tr><td>3-per-em space:</td><td> <span> </span> or <span> </span></td></tr>
<tr><td>4-per-em space:</td><td> <span> </span> or <span> </span></td></tr>
<tr><td>6-per-em space:</td><td> <span> </span></td></tr>
<tr><td>figure space:</td><td> <span> </span> or <span> </span></td></tr>
<tr><td>punctuation space:</td><td> <span> </span> or <span> </td></tr>
<tr><td>thin space:</td><td> <span> </span> or <span> </span></td></tr>
<tr><td>hair space:</td><td> <span> </span> or <span> </span></td></tr>
</table>
这篇关于在HTML中是否还有其他半空格,em-space,en-spaces等空白代码,如& nbsp?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!