angelleye Posted April 26, 2010 Share Posted April 26, 2010 This should be real simple I just don't know how to do it. I'm using PayPal IPN to process order data. IPN is setup to automatically re-try the IPN if doesn't receive a 200 OK response back from the IPN script. In my solution, though, I'm actually storing any MySQL errors and notifying the site owner so the script actually does successfully complete and send a 200 OK back to PayPal, therefore, the IPN is not re-tried. I'd like to send a 500 (or anything other than 200) back to PayPal when this happens, but of course, the script still needs to run successfully. Is there a way I can use header() or anything to force a specific response code back? This way if it's simply a matter of MySQL timing out (which tends to happen on shared servers sometimes) PayPal's system will re-try and I won't have to enter it myself. Any information on this would be greatly appreciated. Thanks! Quote Link to comment Share on other sites More sharing options...
andrewgauger Posted April 26, 2010 Share Posted April 26, 2010 Try: <?php header('x', TRUE, 500);?> http://www.php.net/manual/en/function.header.php#93870 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.