PayPal Return Url for different languages

  • Posts: 15
  • Thank you received: 1
4 years 10 months ago #322907

-- HikaShop version -- : 4.3.0
-- Joomla version -- : 3.9.20

Hello,
Is it possible in the "HikaShop Paypal payment plugin" to customize the page to be inserted in the "Return URL" for each language?

THX

Please Log in or Create an account to join the conversation.

  • Posts: 84025
  • Thank you received: 13615
  • MODERATOR
4 years 10 months ago #322930

Hi,

No, but that's a good idea.
Add the code:

$paymentOptions->payment_params->return_url = hikashop_translate($paymentOptions->payment_params->return_url);
before the line:
foreach(get_object_vars($order) as $key => $val) {
in the file administrator/components/com_hikashop/classes/cart.php
We'll add that change on our end too for the next version of HikaShop, that way, you won't have to do anything when you update.

Then, instead of entering a URL in that "return URL" parameter, you can enter a translation key (for example MY_RETURN_URL).
And then, in the Languages tab of the HikaShop configuration, for each language, you can add such translation override:
MY_RETURN_URL="xxx"
where xxx is the URL you want for the language.

The following user(s) said Thank You: franchina

Please Log in or Create an account to join the conversation.

Time to create page: 0.061 seconds
Powered by Kunena Forum