1

当我收到通过我的 rails 应用程序发送的确认电子邮件时,我使用此代码

<a href='mailto:John%20Doe<Johndoe@random.com>?subject=Billing%20Submission'>LINK</a>

出现在所有不同电子邮件中的电子邮件都很好,除了 aol。

在 aol 中,它显示为:?subject=Billing%20Submission'>LINK

有没有办法在不影响添加名称的情况下解决这个问题?

4

1 回答 1

3

代替

<a href='mailto:John%20Doe<Johndoe@random.com>?subject=Billing%20Submission'>LINK</a>

<a href='mailto:John%20Doe%3CJohndoe@random.com%3E?subject=Billing%20Submission'>LINK</a>

>afterJohndoe@random.com实际上是结束a(anchor) 的起始标签。

对和签名使用等效的 URL 编码。< (%3C)> (%3E)

于 2014-05-28T20:03:45.727 回答