VerifyIPN Method
Verifies the IPN received by the merchant.
Object Oriented Interface
public function doVerifyIPN();
Procedural Interface
inpaypal_ipn_do_verifyipn($res);
Remarks
This method verifies the Instant Payment Notification (IPN) sent to the merchant. The postdata from the received IPN should be passed to the FillFormVars method, or parsed manually into the FormVars property. Then simply call VerifyIPN to check if the IPN was really sent by PayPal. The result of that check is stored in the Response property.
A code example is shown below:
class.FillFormVars(Request.Form()) class.VerifyIPN() If (class.Response = "VERIFIED") Then ProcessOrder() ' Process the order Else LogError() ' Log the error and ignore this fraudulent IPN. End IfIf the IPN is verified, you may use the data contained within the IPN to ship the package. Alternatively, you may use the TransactionDetails class to download more detailed information about the transaction before sending a package.