I'm the developer of Hotspots : https://compojoom.com/joomla-extensions/hotspots
I currently have a client who is using gtranslate PRO and he has problems with my extension. Now what is happening is that when you select a new language -> the domain name changes. Hotspots makes an ajax request to get the data. But because it makes an ajax request to the main domain and not to the subdomain -> the cross domain browser policy comes into place and no request takes place.
I use the Juri::base() function to determine the domain name to which to send the request. Normally if you are on example.com -> it will return example.com. If you are on example.com/something -> it will return example.com/something . if you are on de.example.com -> it should return de.example.com . But with gtranslate it returns example.com ...
So I though ok, maybe we can modify the javascript to read the window.location and I tried to execute the ajax query directly - it worked and maybe this is a possible solution, but there is another problem. The response to my ajax request is a json object. But in in this case when I send the request through the de.example.com then my response starts with % and ends with
- Code: Select all
<!-- delivered by GTranslate v4.3.3 visit http://gtranslate.net -->
This is going to brake the application as it expects a json object. Any ideas/recommendation on what to do?
Kind regards,
Daniel
https://compojoom.com