开发者

PHPMailer Works on WAMP but not on Production Server

Hello I'm trying to use PHPMailer to send emails via SMTP. So, on my development server (WAMP on my computer), it works fine. The mail server I use is mail.jackbusch.net which is on the same shared host that I am going to upload the site to for production.

But when I DO upload the website, PHP mailer stops working and returns SMTP: Error: Could Not Authenticate (when I try to use localhost as the server) and SMTP Error: Could Not Connect (when I type in the full smtp serve开发者_运维问答r name--i.e. mail.jackbusch.net).

This seems odd to me since I have several Wordpress installations that send email notifications just fine--and WP uses Phpmailer, correct?

I don't even know where to begin on fixing this?

EDIT: Thanks for your suggestions--I ended up just using the PEAR Mail package and it works perfectly fine.

I used the second example shown here: http://email.about.com/od/emailprogrammingtips/qt/PHP_Email_SMTP_Authentication.htm

I think one key difference is that before I was using Port 26, and the second time I was using the SSL port for my web host (a small orange). For whatever reason, it all worked out this time.


Used PEAR Mail package instead with the SSL example shown here: http://email.about.com/od/emailprogrammingtips/qt/PHP_Email_SMTP_Authentication.htm

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜