如何在jsp中获取邮件传递报告

时间:2015-05-08 09:50:37

标签: java jsp

在我的java项目项目中,我喜欢向群组或单个用户发送邮件。我想知道是否必须为发件人发送邮件。如果邮件地址有误,请转到报告。

1 个答案:

答案 0 :(得分:1)

There is no standard way of doing this that's accepted and honored across the board. I see that you have some options, though:

Add a header "Return-Receipt-To" with your e-mail address in the value. If the recipient of the e-mail has a client which honors this header, then a return receipt will be sent to you when the e-mail is opened. This is not reliable, mind you, as the user can always decide not to send the receipt, even if he has a client that supports it.

Add an image into your e-mail that loads from your server and put a parameter on the image that includes the user's e-mail address. When the e-mail loads, the image will load from your server. Write a script that collects the e-mail parameter and then delivers a blank image. This is also not reliable, however, as many mail clients prompt users if they wish to download images and they can always choose not to. Also, some (mostly older) e-mail clients do not support images.

Perhaps the most reliable way is not to include the message in your e-mail at all. Include only a link to a website where the message can be read, and include their e-mail address or a unique code in the link. This way, you know exactly who read the message. Of course, this has the downside that people aren't actually getting the message in their inbox, and they also may choose not to go to the website to read it.

Ultimately, I think you're going to have to come up with a creative solution to solve this problem, unless you're happy getting spotty results.

Please refer this Link