News:

You may pay someone to create your store, or you visit our seminar and become a professional yourself with the silver certification

Main Menu

Paypal IPN bug

Started by gripped, May 22, 2014, 10:19:41 AM

Previous topic - Next topic

gripped

Since I updated my production site to 2.6.2 last night I noticed orders paid with paypal were not confirming.
Checking on Paypal the ipn's had been sent

From the error.log
[Thu May 22 01:26:26 2014] [error] [client 173.0.81.1] PHP Warning:  array_key_exists() expects parameter 2 to be array, null given in /var/www/ecigsoutlet.co.uk/htdocs/plugins/vmpayment/paypal/paypal.php on line 639
[Thu May 22 01:26:33 2014] [error] [client 146.90.107.111] PHP Notice:  Undefined variable: paypal_data in /var/www/ecigsoutlet.co.uk/htdocs/plugins/vmpayment/paypal/paypal.php on line 590, referer: https://www.paypal.com/uk/cgi-bin/webscr?cmd=_flow&SESSION=foo&dispatch=bar
[Thu May 22 01:26:33 2014] [error] [client 146.90.107.111] PHP Notice:  Trying to get property of non-object in /var/www/ecigsoutlet.co.uk/htdocs/plugins/vmpayment/paypal/paypal/tmpl/stdresponse.php on line 42, referer: https://www.paypal.com/uk/cgi-bin/webscr?cmd=_flow&SESSION=foo&dispatch=bar
[Thu May 22 01:26:33 2014] [error] [client 146.90.107.111] PHP Notice:  Trying to get property of non-object in /var/www/ecigsoutlet.co.uk/htdocs/plugins/vmpayment/paypal/paypal/tmpl/stdresponse.php on line 42, referer: https://www.paypal.com/uk/cgi-bin/webscr?cmd=_flow&SESSION=foo&dispatch=bar


I'm guessing this changed line (639) plugins/vmpayment/paypal/paypal.php might be at fault ? Returning a null array ?
$paypal_data = vRequest::get('post');

Anyway I have reverted the whole plugins/vmpayment/paypal folder back to the 2.6.0a code and its's working again now.

Paypal Standard

GJC Web Design

hmm - in vm2.6.2 there is public static function getPost( )  in administrator\components\com_virtuemart\helpers\vrequest.php

is that in your install?
GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

gripped

It is


public static function getPost( ){
return  filter_var_array($_POST, FILTER_SANITIZE_STRING);
}

GJC Web Design

hmm - very odd - alatak ?
GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

Milbo

There will be an update, today.
Should I fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/

gripped


e-trader

Will the update now work using the joomla update system? (the currently listed updates do not function)?

gripped

Live update has been removed because the joomla update is more reliable.

e-trader

Yes and ironically, the VM updates listed on the joomla update do not work.

Milbo

Today with the vm2.6.4?
Should I fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/

patrik60

Works fine with 2.6.4

Regards
Patrik

hegbi

Hi, still having this problem, updated all J2.5.20 / V2.6.4
error log
[25-May-2014 07:09:05 America/Chicago] PHP Notice:  Undefined variable: paypal_data in /***/plugins/vmpayment/paypal/paypal.php on line 590
[25-May-2014 07:09:05 America/Chicago] PHP Notice:  Trying to get property of non-object in /***/plugins/vmpayment/paypal/paypal/tmpl/stdresponse.php on line 42
[25-May-2014 07:09:05 America/Chicago] PHP Notice:  Trying to get property of non-object in /***/plugins/vmpayment/paypal/paypal/tmpl/stdresponse.php on line 42
IPN from PayPal is OK status 200 but not receiving anything (missing total value and currency)
What else to try?

alatak

Hello
Thank you for reporting thoses notices: i have fixed the code for this case.
You get them because you did not received an IPN.

If you were receiving an IPN before, and you updated to 2.6.4 both the component and aio, i do not see any reason why it should not work.
Can you activate the log option in the paypal configuration to check if there is any message logged that can help me to understand why you get this problem?

hegbi

Thank you for the answer.
First problem, the test site was under "Site Lock" (JShowroom). Reinstalled everything, pics changed from .png to .gif, unlocked the site, changed that both e-mail addresses are the same and now I am at least receiving e-mails, changed statuses and invoices! I think the main problem here was that I was too tired :)

Still shows those same PHP Notices in error.log and there is a total value & PayPal Transaction Id missing when redirected back to my site from PayPal. Everything else looks great in e-mails and on my web when you go back and check the order but when I check phpMyAdmin table *****_virtuemart_payment_plg_paypal, there are three lines for the same order (pending, confirmed by shoper, confirmed) but the last two are empty besides the order number in row "paypal_response_invoice".
Pls find logs attached.

Payment Name   PP PayPal account needed Sandbox (3)
Order Number   d602026
Total Amount   

Also, sometimes I receive e-mails like this:
An error with your payment paypal on your store *****.**. The details are logged in the file https://www.*****.**/administrator/index.php?option=com_virtuemart&view=log&task=edit&logfile=paypal.3.log.php

alatak

Hello
I cannot download your file. Please send it via PM.