- Posts: 37
- Thank you received: 1
HikaShop PayPal plugin truncates 'state'
13 years 7 months ago #88944
by tidosho
HikaShop PayPal plugin truncates 'state' was created by tidosho
Hi there:
I have noticed during testing that when my test customer has a billing address_state of 'Oxfordshire' the HS PayPal plugin actually sends a 3-letter code to PayPal, in this case 'OXF'. I assume this is what PayPal expects, but when PayPal shows the billing address to the customer they will see the 3-letter code ... which they might not expect. Has anyone encountered problems with this?
Regards,
Martin
I have noticed during testing that when my test customer has a billing address_state of 'Oxfordshire' the HS PayPal plugin actually sends a 3-letter code to PayPal, in this case 'OXF'. I assume this is what PayPal expects, but when PayPal shows the billing address to the customer they will see the 3-letter code ... which they might not expect. Has anyone encountered problems with this?
Regards,
Martin
Please Log in or Create an account to join the conversation.
13 years 7 months ago #89113
by nicolas
Replied by nicolas on topic HikaShop PayPal plugin truncates 'state'
Hi,
If you want to, you can remove the state from the PayPal form by removing the line:
in the file plugins/hikashoppayment/paypal/paypal.php
However, that field is required to US addresses and it has to be the code of the state not the name based on the paypal API documentation. So if you remove it and have US citizens buying on your website, it will probably generate an error on PayPal website if you remove the state.
If you only sell in the UK, that won't be a problem though.
If you want to, you can remove the state from the PayPal form by removing the line:
Code:
$vars["state"]=@$order->cart->$address_type->address_state->zone_code_3;
in the file plugins/hikashoppayment/paypal/paypal.php
However, that field is required to US addresses and it has to be the code of the state not the name based on the paypal API documentation. So if you remove it and have US citizens buying on your website, it will probably generate an error on PayPal website if you remove the state.
If you only sell in the UK, that won't be a problem though.
The following user(s) said Thank You: tidosho
Please Log in or Create an account to join the conversation.
Time to create page: 0.150 seconds