Q: Paypal ipn script not called when refunding I've been using a script for years and it's working great: when a user buys something with Paypal, the script is called and it updates my database (and sends the download instructions to the customer).
Now I want to improve this script so that when I refund somebody, it's updated in my database.
I added a condition in my script, in the switch(payment_status) part of the script: 
If the payment status is "Refunded", then my script will update the database and mark the transaction as refunded.
My problem is that I already refunded someone, and the IPN script wasn't called... 
Is it normal ?
I saw a post of someone who had the opposite problem : he was asking what to do because the ipn script was executed on refunds. For me it's not the case...
Any idea of what's going on and what I should do ?
Thanks.

A: Are you sure it wasn't called?  It's possible it was called but wasn't able to complete successfully because of a syntax error or something like that.  You could check your web logs for something like that.  You can also check the IPN History in your PayPal account to see if they're actually sent but are failing.
Also make sure you have IPN configured in the PayPal profile.  It's possible you were simply using the notify_url parameter in payment requests to get IPN's for the payment, but if you don't have a URL setup in your PayPal profile then nothing would be sent for a refund.  
