• 1

Read this first!

We do not monitor these forums. The forum is provided to exchange information and experience with other users ONLY. Forum responses are not guaranteed.

However, please submit a ticket if you have an active subscription and wish to receive support. Our ticketing system is the only way of getting in touch with RSJoomla! and receiving the official RSJoomla! Customer Support.

For more information, the Support Policy is located here.

Thank you!

TOPIC: Multilanguage return url

Multilanguage return url 7 years 8 months ago #35516

  • gianluca
  • gianluca's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 12
Hello,
I would like a multilanguage return url. Example:
for Italian: www.mysite.com/grazie.html
for English: www.mysite.com/thanks.html
for French: www.mysite.com/merci.html
ect...
Is it possible, please? Thanks.
The administrator has disabled public write access.

Multilanguage return url 7 years 8 months ago #35536

  • dragos
  • dragos's Avatar
  • OFFLINE
  • Administrator
  • Posts: 557
  • Thank you received: 102
Hello,

The following article should provide you with more than a starting point for setting up the 'Return URL' field based on the language used in the front-end:

www.rsjoomla.com/support/documentation/r...in-the-frontend.html
The administrator has disabled public write access.

Multilanguage return url 7 years 1 week ago #36645

  • gianluca
  • gianluca's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 12
Hello, that guide doesn't fix my goals.
Here what I need: I have a multilanguage website (IT - EN), form labels al already translated. My form allow users to choose between two payment methods: Credit Card (PayPal) and Bank Tranfer (Offline), so I using PayPal and offline plugins.

I need to set up 4 different urls for these fields:

- Return URL (Rsform>Configuration>PayPal tab): an url for IT and a different url for EN [this is used when user choose PayPal method]

- Cancel URL (Rsform>Configuration>PayPal tab): an url for IT and a different url for EN [this is used when user choose PayPal method]

- Language code (Rsform>Configuration>PayPal tab): an code for IT and a different code for EN [this is used when user choose PayPal method]

- Return URL (Rsform>Manage forms>My form>Property tab>Info form): an url for IT and a different url for EN [this is used when user choose Offline method]

How can I achieve my goals, please? Thanks.
The administrator has disabled public write access.

Multilanguage return url 6 years 11 months ago #36821

  • gianluca
  • gianluca's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 12
Here how I solved:
Under 'Script called after form has been processed' I added:
$paypal = RSFormProPayPal::getInstance();
$lang =& JFactory::getLanguage();
$language=$lang->getTag();
 
if ($language=="en-GB") {
    if($_POST['form']['choosePayment']== 'paypal') {
        $paypal->args['return'] = 'http://www.english-redirect.com';    
        $paypal->args['cancel_return'] = 'http://www.english-redirect.com';
    } else {
        header('Location: http://www.english-redirect.com');
        exit;
    }
}
The administrator has disabled public write access.
  • 1

Read this first!

We do not monitor these forums. The forum is provided to exchange information and experience with other users ONLY. Forum responses are not guaranteed.

However, please submit a ticket if you have an active subscription and wish to receive support. Our ticketing system is the only way of getting in touch with RSJoomla! and receiving the official RSJoomla! Customer Support.

For more information, the Support Policy is located here.

Thank you!