WORKS!!!!!![]()
WORKS!!!!!![]()
Hi ParadiseFun,
Please let us know what you did to make it work?
I have tried making the same change and it messes up my Admin/payment page (all the right hand side goes missing).
The error I get seems to be linked with the handling amount.
I have 0 handling set in all my shipping but it still adds .15 to my handling amount as well as my Tax amount.
Request Parameters: {DoExpressCheckoutPayment} Array (
[ITEMAMT] => 1.00
[HANDLINGAMT] => 0.15
[SHIPPINGAMT] => 0.00
[TAXAMT] => 0.15
[AMT] => 1.00
The cost should be £1 including vat (0.85 plus 0.15)
I did this:
And works in my shopUpdate: To apply this patch without using the patch command, follow these steps:
1) Backup your files, database, and everything else that matters
2) Make a copy of includes/modules/payment/paypalwpp.php and call it includes/modules/payment/paypalwpp.php.orig
3) Edit the file includes/modules/payment/paypalwpp.php
at line 1446 add this code:
if (DISPLAY_PRICE_WITH_TAX == true)
$optionsST['ITEMAMT'] -= $optionsST['TAXAMT'];
I've included a copy of just this code in the attached file, I recommend copying & pasting it from there, so the indentation is correct.
4) Save the file, enjoy :)
Hi guys,
i have applied the patch as per http://www.zen-cart.com/forum/showthread.php?t=97762
and is working fine BUT. if i put any transactions though for $2000 or more it comes up with the 10413 error.
please help!!!!!
running on v1.3.8a, with no vouchers discounts etc.
logs attached.Paypal_CURL_EC-38G8794034701293K_a3pD.zip
Hey Guys,
Not sure if you have found a solution yet but here is one that worked for me when all the others failed or created more problems.
http://www.zen-cart.com/forum/showpo...1&postcount=22
Hope it works.
I believe the problem lies in this line in the file:
/includes/modules/payment/paypalwpp.php
$response = $doPayPal->DoExpressCheckoutPayment($_SESSION['paypal_ec_token'],
$_SESSION['paypal_ec_payer_id'],
number_format((isset($options['AMT']) ? $options['AMT'] : $order_amount), 2),
$options);
The value of $options['AMT'] may already contain a formatted string such as 1,050.99. In the line above, it is formatted again by the number_format function which may now result to a truncated value of 1. This causes a mismatch now with the original value which should still be 1050.99. This may not affect values less than 1000.
To fix, I changed the above code to:
if (isset($options['AMT']))
{
$response = $doPayPal->DoExpressCheckoutPayment($_SESSION['paypal_ec_token'],
$_SESSION['paypal_ec_payer_id'],
$options['AMT'],
$options);
}
else
{
$response = $doPayPal->DoExpressCheckoutPayment($_SESSION['paypal_ec_token'],
$_SESSION['paypal_ec_payer_id'],
number_format($order_amount, 2),
$options);
}
Hope that helps!
packet8bit
![]()
My old store works perfectly with Zen Cart.
Setting up a new store zen cart 1.38a and ran into this problem with PayPal Express Checkout.
Fixed it without editing any files.
Basically i needed Shipping, Sub Total and Order Total all switched on in the admin/ order total section.
If even one was switched off i would get the PayPal error.
Now it's working perfectly.
So i would recommend people try switching the shipping - ot_shipping, sub total - ot_subtotal and the order total - ot_total all on and see if that helps with the problem as it fixed mine.
Last edited by need_help; 3 Jul 2009 at 05:51 PM. Reason: new data
Explain to me why i was getting the exact error message others have wrote about on this page and i tried EVERYTHING to fix the issue.
Nothing worked.
I switched on those modules ( one was already switched on but i switched other two on ) After switching those modules on everything is perfect.
Now it's no coincidence my other Zen Cart store which incidentally i set up a year and a half ago has always worked perfectly with PayPal and it has always had those 3 things switched on.
So perhaps it won't be a fix for other people's problems but don;t come here and tell me it isn't that simple.
Because it was that simple for me.
I have read the thread you know and spent about eight hours trying to fix the issue today before stumbling across a fix for myself so while you may not think it's simple it certainly seemed a simple fix for me.