0
If you access this site GCMC Advocacia You may notice that the menu will only change language if you double-click the flag. This is because the page is not running the script that loads the menu according to the language of the first time. I imagine it’s something related to jQuery and AJAX, but I don’t have enough experience to do the script. Can you please help me?
I’m using this PHP code:
$en = explode("/", $_SERVER['HTTP_REFERER']); $idioma = $en[4];
It is he who changes the language by popping the url and detecting if the string '/en/'
is found in the url as soon as the menu changes language. I need to run the PHP script really every refresh allowing immediate menu exchange.
This information is not enough for someone to help you. Why do you think it is related to Ajax and/or jQuery? The language links look like common links, which do not use ajax. You may have a logic problem in your PHP (generating the menu before resetting the language).
– bfavaretto
This question is the same as this http://answall.com/questions/6299/load-post-sem-refresh-da-pagina-com-ajax-e-jquery?
– Maniero