[resolved] [debugged] browser language undetected with IE8 (3 posts)

  1. z8po
    Posted 3 years ago #

    all is in the title, if you set xililanguage with browser language with IE8, and two favorite language (fr-FR and en-EN ) it won't work. I didn't test with IE7 and IE6 but should be the same bug. There is below the corrected function match_languages() line 2386 of the xili-language.php file.

    // to debug just add "$browserlanguage = strtolower($browserlanguage);" after the first foreach loop of match_languages() function, because IE send HTTP header in uppercase, and the function match_languages() line 2386 of xili-language.php file compare with lowercase.

    function match_languages ( $listofprefs, $listlanguages ) {
    			foreach($listofprefs as $browserlanguage => $priority) {
    					/* match root languages to give similar in site  - first : five chars langs*/
    					$browserlanguage = strtolower($browserlanguage);

    I wish it will save times. Great add-on, better written than q-translate, congratulation ! i luv the autocreation of translated post. For more information, you can contact me on z8po.dyndns.info or @z8po.


  2. Michel - xiligroup dev
    Plugin Author

    Posted 3 years ago #

    Many thanks for your active contribution...
    I will add these modified lines in next release...
    As I just said in a today support email, IE world is very strange...

    I will keep you informed directly.


  3. z8po
    Posted 3 years ago #

    i'm honored ;) maybe there is a better way to do it, i patched it on the fly, i'll take a look this evening maybe better can be done.
    Just IE is a piece of s**t, microsoft never care about web standard.

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • xili-language
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic