【问题标题】:getting rid of space with the superscript in html emails用 html 电子邮件中的上标去除空格
【发布时间】:2012-06-01 14:24:32
【问题描述】:

上标在行高之间留下很大的空间。

代码是

<span style="position:relative; bottom:0.2em; font-size: 0.8em">&reg;</span>

我没有使用&lt;sup&gt;&lt;/sup&gt; 标签,因为它在行高上也留下了很大的空隙。

有解决办法吗。我知道position:relative 在前景中表现不佳。有什么替代方案?

【问题讨论】:

    标签: html css outlook html-email


    【解决方案1】:

    我在jsFiddle做了一些实验,我想你可以使用:

    <sup style="line-height: 0">&reg;</sup>
    

    在Firefox中它不会增加行间距

    【讨论】:

    • 除 OUTLOOK 2007 ON MAC 之外的所有内容都可以正常工作 :(。我认为 标记会在此客户端上一直留下行高
    【解决方案2】:

    我通过增加包含段落&lt;p&gt;line-height 解决了这个问题

    【讨论】:

      【解决方案3】:

      应用上标时,Outlook 会填充行高。一种解决方法(需要注意!)是执行以下操作: 申请

      <style="mso-line-height-rule:exactly;"> 
      

      &lt;td&gt; 如果单元格中的行高没有偏差并且没有使用图像。 !!!(这很重要,因为如果应用,Outlook 2010 会截断图像) 然后,应用

      <span (or sup) style="font-size: (2px or more smaller than actual font size); line-height:0; vertical-align:3px;" 
      

      在包装上标的 span 标记中。

      查看: http://emaildude.blogspot.com/2011/06/superscript-and-line-heights.html

      【讨论】:

        猜你喜欢
        • 1970-01-01
        • 1970-01-01
        • 2016-09-14
        • 1970-01-01
        • 2018-11-22
        • 2012-09-11
        • 2023-04-09
        • 2015-02-08
        • 1970-01-01
        相关资源
        最近更新 更多