Zen Cart Logo
Forums / PayPal Express Checkout support / Stuck in a loop with NZ vs NZD as currency

Stuck in a loop with NZ vs NZD as currency

Locked

Views: 5,360

Results 1 to 20 of 27
This thread is locked. New replies are disabled.
26 Mar 2007, 4:13 AM
#1
hostinz avatar

hostinz

New Zenner

Join Date:
Mar 2007
Posts:
16
Plugin Contributions:
0

Stuck in a loop with NZ vs NZD as currency

When i installed the paypal module i tested it and it came up with the error can't connect to paypal site bla, bla,bla (10426). So i browsed the forums looking for an answer and found the paypal update thread.

So i then uninstalled the paypal express checkout module and uploaded all the files onto my server from the Patch Issued March 21, 2007 (the lastest one). Now I don't get any error messages but instead i am stuck in a loop. It goes from step one, then to two, then to three, i click confirm order then it goes back to step 2 again.

I get the following error sent to my email address from paypal:-
10426 Transaction refused because of an invalid argument. See additional error messages for details. - Order total is invalid.
I'm not sure what order total is invalid means or how to fix it. :dontgetit Any idea's?

26 Mar 2007, 9:45 PM
#2
hostinz avatar

hostinz

New Zenner

Join Date:
Mar 2007
Posts:
16
Plugin Contributions:
0

Re: Stuck in a loop with NZ vs NZD as currency

just a quick update on this matter. I talked with my hosting company here in nz just to check to see if i need a curl proxy server etc and they said that curl is already activated on their network and I shouldn't need to use a proxy address.
So in config>my store> the curl proxy status is set to false and the curl proxy address is left blank. I'm not sure what else to do really. Im stuck! :down:

27 Mar 2007, 5:13 AM
#3
hostinz avatar

hostinz

New Zenner

Join Date:
Mar 2007
Posts:
16
Plugin Contributions:
0

Re: Stuck in a loop with NZ vs NZD as currency

ok here is a copy of my log file. please can someone have a look and see what is going wrong here:-

2007-03-27 05:05:23
-------------------
(live transaction) --> https://api-3t.paypal.com/nvp
Request Headers: 
Array
(
    [0] => Content-Type: text/namevalue
    [1] => X-VPS-Timeout: 45
    [2] => X-VPS-VIT-Client-Type: PHP/cURL
    [3] => X-VPS-VIT-Integration-Product: PHP::Zen Cart - WPP-NVP
    [4] => X-VPS-VIT-Integration-Version: 0.1
)


Request Parameters: {SetExpressCheckout} 
Array
(
    [LOCALECODE] => US
    [PAYMENTACTION] => Sale
    [NOSHIPPING] => 1
    [email] => [email protected]
    [PHONENUM] => 5476304
    [AMT] => 0.00
    [RETURNURL] => http://www.hostinz.co.nz/shoppingcart/ipn_main_handler.php?type=ec
    [CANCELURL] => http://www.hostinz.co.nz/shoppingcart/index.php?main_page=checkout_shipping&ec_cancel=1
    [PAGESTYLE] => Primary
    [METHOD] => SetExpressCheckout
    [CURRENCYCODE] => NZD
    [USER] => sales_api1.hostinz.co.nz
    [PWD] => ****************
    [VERSION] => 2.3
    [SIGNATURE] => ****************************************************y0KR
)


Response: 
Array
(
    [TIMESTAMP] => 2007-03-27T05:05:24Z
    [CORRELATIONID] => 795d014a1a852
    [ACK] => Failure
    [L_ERRORCODE0] => 10426
    [L_SHORTMESSAGE0] => Transaction refused because of an invalid argument.  See additional error messages for details.
    [L_LONGMESSAGE0] => Order total is invalid.
    [L_SEVERITYCODE0] => Error
    [VERSION] => 2.300000
    [BUILD] => 1.0006
    [CURL_ERRORS] => 
)


SetExpressCheckout, Elapsed: 1526ms -- Failure

TIMESTAMP=2007%2d03%2d27T05%3a05%3a24Z&CORRELATIONID=795d014a1a852&ACK=Failure&L_ERRORCODE0=10426&L_SHORTMESSAGE0=Transaction%20refused%20because%20of%20an%20invalid%20argument%2e%20%20See%20additional%20error%20messages%20for%20details%2e&L_LONGMESSAGE0=Order%20total%20is%20invalid%2e&L_SEVERITYCODE0=Error&VERSION=2%2e300000&BUILD=1%2e0006&CURL_ERRORS=
```Thanks
27 Mar 2007, 7:20 AM
#4
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: Stuck in a loop with NZ vs NZD as currency

[AMT] => 0.00

[ACK] => Failure
[L_ERRORCODE0] => 10426
[L_SHORTMESSAGE0] => Transaction refused because of an invalid argument.  See additional error messages for details.
[L_LONGMESSAGE0] => Order total is invalid.

You can't place an order for zero dollars.

I suspect you've deleted the USD currency from your store, and you've left the PayPal module set to accept payments in USD only, rather than NZD.
What are the settings for your module in Zen Cart admin ?

27 Mar 2007, 10:23 AM
#5
hostinz avatar

hostinz

New Zenner

Join Date:
Mar 2007
Posts:
16
Plugin Contributions:
0

Re: Stuck in a loop with NZ vs NZD as currency

These are my settings for the paypal express module:-**

Enable this Payment Module**
True

Sort order of display.
3

Payment Zone
--none--

Set Order Status
Processing [2]

Set Unpaid Order Status
Pending [1]

Set Refund Order Status
Pending [1]

Express Checkout: Require Confirmed Address
No

Express Checkout: Select Cheapest Shipping Automatically
Yes

Express Checkout: Skip Payment Page
Yes

Express Checkout: Automatic Account Creation
Yes

Payment Action
Final Sale

Transaction Currency
Only NZD

PayPal Page Style
Primary

API Signature -- Username
sales_api1.hostinz.co.nz

API Signature -- Password


API Signature -- Signature Code


Live or Sandbox
live

Debug Mode
Log File

Yes I have deleted the USD curreny but i have set up a NZD currency as follows:-

Title: New Zealand Dollar Code: NZ
Symbol Left: $ Symbol Right: NZD
Decimal Point: . Thousands Point: , Decimal Places: 2
Last Updated: Value: 1.00000000
Example Output:
$30.00NZD = $30.00NZD

27 Mar 2007, 10:34 AM
#6
hostinz avatar

hostinz

New Zenner

Join Date:
Mar 2007
Posts:
16
Plugin Contributions:
0

Re: Stuck in a loop with NZ vs NZD as currency

forgot to add:-
I noticed that when i was in localization > currencies > edit > and i changed the code from NZ to NZD all the prices on my products displayed 0. why did this happen? What does this code do exactly? has this got anything to do with my paypal problem?

27 Mar 2007, 3:49 PM
#7
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: Stuck in a loop with NZ vs NZD as currency

The correct currency code is NZD. If you were using NZ, then the module was trying to convert from "NZ" to "NZD" in order to do the payment. Since it didn't find NZD, nor USD, it used an exchange rate of 0, thus ending up with submitting a $0.00 order.

So, yes, you need to have it switch to NZD.
Set NZD as default.

If you've entered "NZ" anywhere else as a currency code, go change it to NZD.

Then log out of your cart, close your browser, perhaps clear your cache, and then test the site again. The prices should switch to NZD instead of 0's.

If that still doesn't switch them, either wait 25 minutes and try again, or add &currency=NZD to your URL to force your current browser session to use NZD instead of what it had memorized as NZ for its active session (which expires after 24 min of inactivity).

28 Mar 2007, 10:28 AM
#8
hostinz avatar

hostinz

New Zenner

Join Date:
Mar 2007
Posts:
16
Plugin Contributions:
0

Re: Stuck in a loop with NZ vs NZD as currency

Thanks for your help...but my currency code was 'NZ' and when I had it this way it displayed all the prices correctly. When I changed to the correct 'NZD' the prices displayed 0.
NZD is the only currency i am using, because that is all i need for my shop so there shouldn't be anything interfering with it. I have tried clearing my cache, waiting 30mins, even tried it on another computer (from which I have never browsed my shop before) but still displays just 0. however i did try adding '&currency=NZD' to the end of the url and the prices displayed properly but obviously I need all the prices to be displayed correctly automatically.

Note: when i added '&currency=NZD' (with my currency code set to 'NZD') paypal express worked fine and so did paypal ipn.

28 Mar 2007, 3:20 PM
#9
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: Stuck in a loop with NZ vs NZD as currency

hostinz:

i did try adding '&currency=NZD' to the end of the url and the prices displayed properly but obviously I need all the prices to be displayed correctly automatically.

Note: when i added '&currency=NZD' (with my currency code set to 'NZD') paypal express worked fine and so did paypal ipn.

Of course. So, the issue is ensuring that your store actually sets NZD as the default currency properly.

DrByte:

If you've entered "NZ" anywhere else as a currency code, go change it to NZD.Did you edit your currency setting in your language files? ie: english.php

  define('LANGUAGE_CURRENCY', 'NZ');
```If so, you need to change 'NZ' to 'NZD' for consistency.
29 Mar 2007, 11:19 AM
#10
hostinz avatar

hostinz

New Zenner

Join Date:
Mar 2007
Posts:
16
Plugin Contributions:
0

Re: Stuck in a loop with NZ vs NZD as currency

Thanks Drbyte!

Like you suggested I changed this in my index.php file:-

// if USE_DEFAULT_LANGUAGE_CURRENCY is true, use the following currency, instead of the applications default currency (used when changing language)
  define('LANGUAGE_CURRENCY', 'NZD');
```It was set to USD instead NZD and my NZD currency in my zen cart admin was set to default thats why it didn't work properly. Paypal and everything works fine now.

Thanks again!
29 Mar 2007, 11:21 AM
#11
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: Stuck in a loop with NZ vs NZD as currency

YAY! :clap:

9 Apr 2007, 4:00 AM
#12
modchipfitters_co_uk avatar

modchipfitters_co_uk

Zen Follower

Join Date:
Sep 2006
Location:
United Kingdom
Posts:
190
Plugin Contributions:
0

Re: Stuck in a loop with NZ vs NZD as currency

i was having simular problem but i found that it was caused by the paypal account i was paying with had insufficiant funds

for some reason if there isnt enough cash in the customers paypal account to pay for the item and the alternate funding source also fails it puts you in a loop

is this the way it is suppose to happen?? maybe it would be better it when it returns you to the payment page there was an error message displayed to let the customer know why it has happened?

9 Apr 2007, 4:03 AM
#13
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: Stuck in a loop with NZ vs NZD as currency

modchipfitters.co.uk:

i was having simular problem but i found that it was caused by the paypal account i was paying with had insufficiant funds

for some reason if there isnt enough cash in the customers paypal account to pay for the item and the alternate funding source also fails it puts you in a loop

is this the way it is suppose to happen?? maybe it would be better it when it returns you to the payment page there was an error message displayed to let the customer know why it has happened?

Haven't experienced that situation yet.
Did you have logging enabled when that happened?
If I can see those logs I can have it trap for that situation ...

9 Apr 2007, 4:06 AM
#14
modchipfitters_co_uk avatar

modchipfitters_co_uk

Zen Follower

Join Date:
Sep 2006
Location:
United Kingdom
Posts:
190
Plugin Contributions:
0

Re: Stuck in a loop with NZ vs NZD as currency

didnt have logging on but gimme 2 mins and ill enable it and post back

9 Apr 2007, 4:12 AM
#15
modchipfitters_co_uk avatar

modchipfitters_co_uk

Zen Follower

Join Date:
Sep 2006
Location:
United Kingdom
Posts:
190
Plugin Contributions:
0

Re: Stuck in a loop with NZ vs NZD as currency

here we go

2007-04-09 05:08:51
-------------------
(live transaction) --> https://api-3t.paypal.com/nvp Request Headers: 
Array
(
    [0] => Content-Type: text/namevalue
    [1] => X-VPS-Timeout: 45
    [2] => X-VPS-VIT-Client-Type: PHP/cURL
    [3] => X-VPS-VIT-Integration-Product: PHP::Zen Cart - WPP-NVP
    [4] => X-VPS-VIT-Integration-Version: 0.1
)


Request Parameters: {GetExpressCheckoutDetails} Array (
    [TOKEN] => EC-7DS84****3054530A
    [METHOD] => GetExpressCheckoutDetails
    [USER] => *********
    [PWD] => ****************
    [VERSION] => 2.3
    [SIGNATURE] => ****************************************************CZRn
)


Response: 
Array
(
    [TIMESTAMP] => 2007-04-09T04:08:51Z
    [CORRELATIONID] => c9c04d39e509b
    [ACK] => Success

[I]*snip*[/I]


)
9 Apr 2007, 4:39 AM
#16
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: Stuck in a loop with NZ vs NZD as currency

oops ... wrong log file. Tha'ts the GetTransactionDetails log, which happens before the actual payment amount is sent/requested.

Can you grab and zip and post all the log files from the 30 seconds of doing the test transaction?

9 Apr 2007, 4:52 AM
#17
modchipfitters_co_uk avatar

modchipfitters_co_uk

Zen Follower

Join Date:
Sep 2006
Location:
United Kingdom
Posts:
190
Plugin Contributions:
0

Re: Stuck in a loop with NZ vs NZD as currency

Here You Go :d

log removed

9 Apr 2007, 5:22 AM
#18
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: Stuck in a loop with NZ vs NZD as currency

modchipfitters.co.uk:

for some reason if there isnt enough cash in the customers paypal account to pay for the item and the alternate funding source also fails it puts you in a loopCan you describe what you mean by "loop" ?

9 Apr 2007, 5:28 AM
#19
modchipfitters_co_uk avatar

modchipfitters_co_uk

Zen Follower

Join Date:
Sep 2006
Location:
United Kingdom
Posts:
190
Plugin Contributions:
0

Re: Stuck in a loop with NZ vs NZD as currency

ok here goes

  1. add to cart - everything fine
  2. click checkout - everything fine i get to step 1 of checkout
  3. i goto stage to payment options - all fine here
    4 click continue - i goto stage 3 order confirmation no problems
  4. click confirm- takes me to paypal log on
    6 loginto paypal - still all ok
  5. click review payment - this should then pay for my item and return me to the completed order screen bit instead i end up at step 2 of the checkout again and no matter what i do it keeps going round from number 4 on this list.

but if i have enough funds in the account it checks out just fine

9 Apr 2007, 5:36 AM
#20
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: Stuck in a loop with NZ vs NZD as currency

Um ... if you haven't got sufficient funds ... it cannot complete the transaction .... what do you want it to do?
Pay for it anyway ?

It should already be giving an error something like:
(10417) We were not able to process your order. Please try again, select an alternate payment method, or contact the store owner for assistance.