For those of you who use the qTranslate-X plugin for WordPress, there is a snippet with which you can get the code of the current language.
1 2 3 4 5 | if (qtranxf_getLanguage() == 'en') { // insert the code for English here } elseif (qtranxf_getLanguage() == 'he') { // insert the code for Hebrew here } |
You can see the language code in the “Languages” tab in the plugin’s settings.