0
startup.js角の流星を使って電子メールを送信し、電子メールにテンプレートデザインを追加するにはどうすればよいですか?私はこれを使用しています:
SMTP = { 名: '[email protected]'、
パスワード: 'alpha123e'、
サーバー: 'smtp.gmail.com'、
ポート:465 }
process.env.MAIL_URL = 'SMTP://' + encodeURIComponentで(smtp.username)+ ':' + encodeURIComponentで(smtp.password)+ '@' + encodeURIComponentで(smtp.server )+ ':' + smtp.port;
流星方法
Meteor.methods({ sendEmail: function (to, from, subject, text) {
check([to, from, subject, text], [String]);
this.unblock();
Email.send({
to: to,
from: from,
subject: subject,
text: text
});
}
});