addReplyTo似乎不起作用

时间:2020-12-29 03:15:04

everyone.

I'm trying to configure a email specifying an email address to reply to using the addReplyTo method and although the email is sent successfully addReplyTo似乎不起作用

我正在尝试使用addReplyTo方法配置指定要回复的电子邮件地址的电子邮件,尽管电子邮件已成功发送

when I log into the email account(octunprg@gmail.com) to read and reply to the email that has just been sent, the email address that appears in the To field is the same email address (octunprg@gmail.com) not the one I indicated using "addReplyTo"(eddysmith1818@gmail.com) when I set the email.

当我登录电子邮件帐户(octunprg@gmail.com)阅读并回复刚刚发送的电子邮件时,“收件人”字段中显示的电子邮件地址是相同的电子邮件地址(octunprg@gmail.com)而不是我在设置电子邮件时使用“addReplyTo”(eddysmith1818@gmail.com)表示了一个。

Is it the normal operation?? Am I doing something wrong??

这是正常的操作吗?难道我做错了什么??

addReplyTo似乎不起作用

            Email email = new SimpleEmail();
            email.setHostName("smtp.gmail.com");
            email.setSmtpPort(587);
            email.setAuthenticator(new DefaultAuthenticator("octunprg@gmail.com", "123456"));
            email.setTLS(true);
            email.setFrom(from, name);// 'eddysmith1818@gmail.com', 'Eddy Smith'
            email.setSubject(subject);
            email.setMsg(message);
            email.addReplyTo(from, name);   // 'eddysmith1818@gmail.com', 'Eddy Smith'             
            email.addTo("octunprg@gmail.com");
            email.send();

1 个解决方案

#1


0  

This may be a mistake in your email client (Gmail, as I see).

这可能是您的电子邮件客户端(我看到Gmail)的错误。

#1


0  

This may be a mistake in your email client (Gmail, as I see).

这可能是您的电子邮件客户端(我看到Gmail)的错误。