News:

You may pay someone to create your store, or you visit our seminar and become a professional yourself with the silver certification

Main Menu

How to create a proper VM URL when Language Filter is activated

Started by miraz, April 12, 2017, 13:13:29 PM

Previous topic - Next topic

miraz

Hi,
I'm working on a payment plugin. I have to pass the plugin's notification URL to the gateway, that will work without further redirection.
When the Langauge Filter plugin is activated, all urls in Joomla are changed from  ..../index.php...  to ..../index.php/en/....
In case the url is used without the /en/, the language filter redirects to the proper url. But the redirection doesn't work for the payment gateway, which treats redirection as an undelivered notification.

I use JROUTE::_ (JURI::root () . 'index.php?option=com_virtuemart&view=pluginresponse......
but it ignores the language filter settings. And causes the language filter redirects.

Adding a parameter &lang=en in helps in Joomla version 3.6.5 but e.g. the older Joomla 2.5.6 still redirects.

I checked other payments plugins but, I didn't find solution. I need a general solution that works for both situations when the Language filter is installed or not.

How can I get this language filtered url in my plugin?
Please help.

Regards,
Miroslav.