ios – Mailgun:使用解析云代码发送图像

ios – Mailgun:使用解析云代码发送图像,第1张

概述我有一个定义为的代码 Parse.Cloud.define("mailgunSendMail", function(request, response) { var Mailgun = require('mailgun'); Mailgun.initialize('photoshare.com', 'APPKey'); 我有一个定义为的代码

Parse.Cloud.define("mailgunSendMail",function(request,response) {               var Mailgun = require('mailgun');               Mailgun.initialize('photoshare.com','APPKey');               Mailgun.sendEmail({                                 to: "[email protected]",from: "[email protected]",subject: "Hello from Cloud Code!",text: "Using Parse and Mailgun is great!",attachment:"ZXhhbXBsZSBmaWxl"                                 },{                                 success: function(httpResponse) {                                 console.log(httpResponse);                                 response.success("Email sent!");                                 },error: function(httpResponse) {                                 console.error(httpResponse);                                 response.error("Uh oh,something went wrong");                                 }                                 });               });

邮件已成功发送,收件人收到邮件但附件丢失.我如何以数据的形式发送附件?

解决方法 根据解析,此时无法在电子邮件中发送附件. Check this link

但是,如果您可以将图像文件包含在HTML代码中,则可以满足您的需求.

HTML: '<HTML><body ><img border="0" src="http://files.parse.com/6ffa6b80-d0eb-401f-b663-22d4a16df004/bfed9ac4-058c-41fc-a0f1-fb6155572c12-ad77a082-453f-42f7-94ef-40c3f3e885e6.png" alt="Pulpit rock" wIDth="300" height="150"></body></HTML>'
@H_403_29@ 总结

以上是内存溢出为你收集整理的ios – Mailgun:使用解析云代码发送图像全部内容,希望文章能够帮你解决ios – Mailgun:使用解析云代码发送图像所遇到的程序开发问题。

如果觉得内存溢出网站内容还不错,欢迎将内存溢出网站推荐给程序员好友。

欢迎分享,转载请注明来源:内存溢出

原文地址: https://outofmemory.cn/web/1024413.html

(0)
打赏 微信扫一扫 微信扫一扫 支付宝扫一扫 支付宝扫一扫
上一篇 2022-05-23
下一篇 2022-05-23

发表评论

登录后才能评论

评论列表(0条)

保存