?
Solved

wordpress, php, windows, iis 6 - wp_mail http error 500

Posted on 2012-04-11
11
Medium Priority
?
789 Views
Last Modified: 2012-08-04
I've inherited a wp site on a windows 2003 box with iis6 and php.

All of a sudden, any mail-related function throws an http 500 error and I get no output.

I've traced through the code to find the offending line: wp_mail ( );

If I comment it out, no error.  (No mail, of course, but no error).  Firebug gives me the http 500 error and some other info but nothing points to a culprit.

HELP!!
0
Comment
Question by:snowdog_2112
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 7
  • 4
11 Comments
 

Author Comment

by:snowdog_2112
ID: 37837630
Update, fwiw.

I reinstalled and did a repair install of PHP on the server.  No difference.  Still getting an HTTP 500 error with anything that calls wp_mail.

I've pointed the SMTP server in WP to an external SMTP server to see if Wireshark would see any packets - nope.

I created a php page in the wp folder that DOES send mail using the php mailer - whatever the stock, default mail command uses.

Thsi tells me it's definitely in WP somewhere.
0
 
LVL 70

Expert Comment

by:Jason C. Levine
ID: 37841041
>> I've pointed the SMTP server in WP to an external SMTP server to see if Wireshark would see any packets - nope.

Hmph.  Can I ask you try it again and this time use the following to configure the email in WordPress?

http://wordpress.org/extend/plugins/configure-smtp/
0
 

Author Comment

by:snowdog_2112
ID: 37843391
Hmph?  Are you the author of the plug-in?

I was in no way suggesting the plug-in is not working.  I get the same http 500 on *any* mail operation, including Contact Form 7 (tried 2 different versions of cf7 too).

I do have it set up as shown in the link.  I was saying I've tried many different settings in an attempt to fix it or at least see if I can get more information pointing to the point of failure.

I've tried:
localhost
<ip of server>  <-- SMTP runs on the same server hosting this WP site.
127.0.0.1
<fqdn of server>
all the above, using port 8025  <-- added 8025 to local SMTP server.

Thanks.
0
Are You Using the Best Web Development Editor?

The worlds of web hosting and web development are constantly evolving. Every year we see design trends change, coding standards adapt and new frameworks/CMS created. With such a quick pace of change it’s easy to get lost trying to keep up.

See if your editor made the list.

 
LVL 70

Expert Comment

by:Jason C. Levine
ID: 37843578
>> Are you the author of the plug-in?

Good lord, no :)  I was hoping that you may have misconfigured something and giving you an admin interface to set SMTP settings in WordPress would have resolved that.  It's hard to gauge your skill level from the post.

>>  I get the same http 500 on *any* mail operation, including Contact Form 7 (tried 2 different versions of cf7 too).

Weird.  Which version of WP is running?
0
 

Author Comment

by:snowdog_2112
ID: 37889783
wordpress 3.0.1

Can't tell a version on configure-smtp
Contact Form 7 is 2.4.1

Still getting the http 500.

Let me know if there's anything else I can check.

My Skill Level (1 - 10, 10 = savant):
Windows - 8
IIS - 7
SMTP - 5
WP - 2
0
 

Author Comment

by:snowdog_2112
ID: 37933372
Still fighting this.  I've wiresharked the $#!+ out of this and can't see anything suggesting issue.

Since I can put a simple php page in the same IIS site and send mail using a php page, I am pretty sure php, iis, and smtp are working, this seems to me to point back to wordpress.

I just don't know enough of wp to know how to replace the wp_mail command with something like the php mail command...
0
 
LVL 70

Expert Comment

by:Jason C. Levine
ID: 37933377
Yeah, I'm not sure how to do it with IIS either.  Can you install WordPress 3.3.2 on a testing domain and see if it will send mail?  It may also be a version specific thing.
0
 

Author Comment

by:snowdog_2112
ID: 37994626
Waiting for my customer to authorize more time to spend chasing my tail on this...

Setting up a lab case would be hours of prep, and even if it works, there's not a good mechanism to transfer it to the problem system - i.e., if it works, that still doesn't tell me *why* it doesn't work on the problem machine, nor how to fix it.
0
 
LVL 70

Expert Comment

by:Jason C. Levine
ID: 37994699
if it works, that still doesn't tell me *why* it doesn't work on the problem machine, nor how to fix it.

No, but we can then refer to the changelog and see what they changed and start chasing it down from there.  

Alternately, if it works in 3.3.2 just upgrade WordPress on the production machine and that's the functional end of the issue.  The philosophical ending can be relegated to hobby status.
0
 

Accepted Solution

by:
snowdog_2112 earned 0 total points
ID: 38237857
Sorry guys - the end use on this has not authorized additional resources (i.e., money) for me to fix the issue.  Thanks all for the help, but I still have no answer.  Hopefully we can do a version upgrade soon and fix it that way.

Thanks again.
0
 

Author Closing Comment

by:snowdog_2112
ID: 38257535
no solution found.
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

So you have coded your own WordPress plugin and now you want to allow users to upload images to a folder in the plugin folder rather than the default media location? Follow along and this article will show you how to do just that!
Originally, this post was published on Monitis Blog, you can check it here . In business circles, we sometimes hear that today is the “age of the customer.” And so it is. Thanks to the enormous advances over the past few years in consumer techno…
The viewer will learn how to dynamically set the form action using jQuery.
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …
Suggested Courses

777 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question