看到Java邮件示例中使用的是Gmail邮箱,但是由于GFW的关系,Gmail经常不能用,根据示例程序可以做到用Sohu发送邮件(但有的时候偶尔失败),但是QQ发送的时候提示异常,收邮件暂时也没有成功,请给一个简单的示例??
图片怎么没有显示呢
从你的截图上看提示登录失败,你先把乱码的问题看一下,看看是什么原因导致登陆失败(对于不同的邮件服务商可能在具体处理上会有所不同),先确认具体的错误才好定位问题。
收邮件暂时可以显示邮件列表了,但还无法通过QQ邮箱发送邮件(提示登陆失败),但是发邮件的代码基本一致(就是换了smtp地址,端口号也试了25 465 587都不行)。 代码已经被我删了,反正记得是Authentication有问题。无所谓了。
{$ item.file.size/1024/1024|number:2 $} MB