在电子邮件中添加JavaScript [英] Add javascript in the email

查看:459
本文介绍了在电子邮件中添加JavaScript的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

电子邮件内可以有一个ajax按钮吗?
我想添加一个类似于谷歌日历会议邀请电子邮件中的按钮的按钮。

Is it possible to have a ajax button inside email? I want to add a button similar to the buttons inside a google calender meeting invitation email.

还是有任何替代选项?

推荐答案

不要指望。大多数(如果不是全部)邮件客户端将拒绝在电子邮件中运行Javascript。

Don’t count on it. Most if not all mail clients will refuse to run Javascript within an e-mail.

如果要包含按钮,请将具有不同链接的图像插入公共网页你的。另外,请务必在邮件内容中包含按钮图片(请参阅 Content-ID ),因为许多邮件客户端现在甚至拒绝加载远程图像。

If you want to include buttons, insert images with different links to a public web page of yours. Also, do include the button images within the mail message itself (and reference them by Content-ID), since many mail clients nowadays even refuse to load remote images.

这正是Google日历所做的。当然,Gmail会识别邀请附件(文字/日历),因此提供了自己的界面对于是/否/也许按钮。

This is exactly what Google Calendar does. Of course, Gmail recognizes invitation attachments (text/calendar), and so provides its own interface for the yes/no/maybe buttons.

这篇关于在电子邮件中添加JavaScript的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆