ViPiN ViPiN - 1 month ago 12
Node.js Question

How to set reply to in emailJS , the nodejs mailer?

I was trying to send a mail using the library

emailjs
in my node app.Everything is working except that I am not able to figure out how to set the '
reply to
' property in the configuration.Here is my code

var email1 = require(node_path + "emailjs/email");

var server1 = email1.server.connect(mail_sever_conf);


//prepare the message
var msg1 = {
from : 'myfrommail@gmail.com',
to:'tomailid@gmail.com',
subject: 'My App mail subject',
text : 'Some mail content',
replyTo : 'notification@myapp.com' //This is what I tried
};


//send the email
server1.send(msg1, function(err, message) { console.log(err || message); });


I dont see how to set that in their github page either, can someone please help me?

Answer

Try to use this:

reply-to

https://github.com/eleith/emailjs/blob/master/smtp/message.js Line : 93

They are just passing as Headers. So it should work.


This was resolved/commented on in an issue raised on the project: https://github.com/eleith/emailjs/issues/54

Comments