【问题标题】:How to Remove Hyperlink underline in Gmail while sending Email template from outlook从 Outlook 发送电子邮件模板时如何删除 Gmail 中的超链接下划线
【发布时间】:2017-08-14 05:39:41
【问题描述】:

今天在将邮件从 Outlook 发送到 Gmail 时遇到了一个新问题。问题是超链接元素显示为下划线。 我在下面试过了。

方法一:

 <td  width="500px" align="center" style=" text-align: left; font-size:1.2em; font-family:Candara; color: #FFFFFF;">
             <a href="mailto:info@example.com" style="color:#fff;text-decoration:none;" target="_blank">info@xxx.com</a>      
    </td>

方法二:

<a href="mailto:info@example.com" style="color:#fff;text-decoration:none !important;" target="_blank">info@ccc.com</a>  

方法三:

  a {text-decoration: none !important; color: #000; cursor: text;}

此代码在浏览器、outlook 中运行良好,问题出在 Gmail 邮箱中。因为 Gmail 在超链接标签后动态附加 span 标签。

我在这里附上了视频参考:

http://recordit.co/OGlkkBiXGX

Given: text-decoration none 它没有被 gmail 盒子采用,因为在 span 标签中添加了一个标签之后。

完整代码

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>mailtest</title>
</head>
<body style="margin:0; padding:0;">
        <table width="582" border="0" cellspacing="0" cellpadding="0" align="center" style="background:black;">
            <tr> 
                <td  width="500px" align="center" style=" text-align: left; font-size:1.2em; font-family:Candara; color: #FFFFFF;">
                    <img style="margin-left:10px;" src="http://codestrz.com/Content/mail/envelope.png" alt="" border="0" height="18" width="18"/> 
                    <a href="mailto:info@example.com" style="color:#fff;text-decoration:none" target="_blank">info@xxx.com</a>      
                </td>
            </tr>
        </table>
    </body>
</html>

我已经尝试过这个简单的标签:

    <p style="color:white;"> EXTRANET.EXAMPLE.COM</p>

后来尝试了没有链接的简单p标签,

outlook 2013中的输出:

[![enter code here][1]][1]

gmail 输出

【问题讨论】:

  • 您能否向我们展示带有附加 &lt;span&gt; 的代码是什么样的?
  • 请看上面提到的视频,它会清楚地显示出来
  • 你的 Outlook 版本是多少?
  • @Narendhran 展望 2013
  • 然后在你的 CSS 中, .myClass,.myClass1{ text-decoration: none;颜色:#FFFFFF; }

标签: css html email outlook


【解决方案1】:

在您的样式中插入; text-decoration:none 后,因为 html 在某些情况下无法读取正确的 css 而没有结束。

【讨论】:

  • 抱歉我的错字,因为 span 标签是动态附加的,所以没有任何效果。
【解决方案2】:

试试这个

 <a href='yourLink' bgcolor="#000000">yourLinkHere</a>

<a href="yourLink" style="color:#CCCCCC; text-decoration:none;"><color="#CCCCCC">yourLink</font></a>

对于 2007 以上的 Outlook 版本,

  • 按 CTRL+SHIFT+ALT+S
  • 右键单击样式和格式窗格中的超链接条目并选择修改
  • 更改超链接的字体设置。 (去掉下划线)

就是这样, 为您创建的所有新消息更改它

  • 启用选项(单选按钮):基于此模板的新文档

【讨论】:

  • @Narendran 我试过不工作,还选择了超链接并删除了它在 Outlook 中工作的下划线,在收到 gmail 中的邮件后,我得到了文本的下划线。
  • 以上代码不起作用,如果您有兴趣在 Outlook 中尝试使用 gmail 发送邮件。究竟发生了什么以便更好地理解。 recordit.co/iAD6BPK7pW
猜你喜欢
  • 2020-08-19
  • 1970-01-01
  • 2020-06-28
  • 1970-01-01
  • 2012-02-18
  • 2018-06-23
  • 1970-01-01
  • 2016-02-29
  • 1970-01-01
相关资源
最近更新 更多