Forum Archive - [solved][GTranslate Pro / Joomla 1.5] alt-attribute / Flags

[solved][GTranslate Pro / Joomla 1.5] alt-attribute / Flags
Dec 12, 2011 4:33 pm by alt_f4
To be honest: GTranslate is working nearly perfect for us... This time, only a little question related to the alt-attribute in the "flag menue" of GTranslate. On our Site (english, translation by GTranslate) http://www.imsware.com the Flags are shown in the upper right corner. On mouse-over the alt-attribute of each language is shown correctly expect the native (first) flag. The mouse-over of the german flag is "English" instead of "German"...but the strange thing is that in the source code everything with the alt-attribute seems to be correct... <img src="/modules/mod_gtranslate/tmpl/lang/blank.png" height="16" width="16" alt="German" /></a> How can I correct this? Regards, alt_f4
Re: [GTranslate Pro / Joomla 1.5] alt-attribute / Flags
Dec 12, 2011 10:11 pm by Edvard
Hi, In the source code I can see this: <a href="javascript:doTranslate('de|de')" title="English" class="flag" style="background-position:-300px -100px;"> As you can see the title is set to English which is being displayed. Did you modify the GTranslate module or it is a bug in our code?
Re: [GTranslate Pro / Joomla 1.5] alt-attribute / Flags
Dec 13, 2011 7:52 am by alt_f4
to be secure, I´ve done a fresh install of the GTranslate module(Joomla 1.5.x.28). I guess, the array is set in the default.php (located in the "tmpl" directory)? In line 11 everything seems to be defined well: $lang_array = array('en'=>'English','ar'=>'Arabic','bg'=>'Bulgarian','zh-CN'=>'Chinese (Simplified)','zh-TW'=>'Chinese (Traditional)','hr'=>'Croatian','cs'=>'Czech','da'=>'Danish','nl'=>'Dutch','fi'=>'Finnish','fr'=>'French','de'=>'German','el'=>'Greek','hi'=>'Hindi','it'=>'Italian','ja'=>'Japanese','ko'=>'Korean','no'=>'Norwegian','pl'=>'Polish','pt'=>'Portuguese','ro'=>'Romanian','ru'=>'Russian','es'=>'Spanish','sv'=>'Swedish','ca'=>'Catalan','tl'=>'Filipino','iw'=>'Hebrew','id'=>'Indonesian','lv'=>'Latvian','lt'=>'Lithuanian','sr'=>'Serbian','sk'=>'Slovak','sl'=>'Slovenian','uk'=>'Ukrainian','vi'=>'Vietnamese','sq'=>'Albanian','et'=>'Estonian','gl'=>'Galician','hu'=>'Hungarian','mt'=>'Maltese','th'=>'Thai','tr'=>'Turkish','fa'=>'Persian','af'=>'Afrikaans','ms'=>'Malay','sw'=>'Swahili','ga'=>'Irish','cy'=>'Welsh','be'=>'Belarusian','is'=>'Icelandic','mk'=>'Macedonian','yi'=>'Yiddish','hy'=>'Armenian','az'=>'Azerbaijani','eu'=>'Basque','ka'=>'Georgian','ht'=>'Haitian Creole','ur'=>'Urdu'); Hmmmpf...any idea? Do you use any further arrays? Maybe it´s related to the ordering or the way you call the tooltip? Best regards, alt_f4
Re: [GTranslate Pro / Joomla 1.5] alt-attribute / Flags
Dec 14, 2011 7:25 am by alt_f4
...to clarify: No changes in the Joomla-module.
Re: [GTranslate Pro / Joomla 1.5] alt-attribute / Flags
Dec 17, 2011 3:38 pm by Edvard
I cannot confirm that there is a issue in the code. Please download and install the latest version.
Re: [GTranslate Pro / Joomla 1.5] alt-attribute / Flags
Dec 19, 2011 8:11 am by alt_f4
In wich files do you build the alt-attributes? Regards, alt_f4
Re: [GTranslate Pro / Joomla 1.5] alt-attribute / Flags
Dec 19, 2011 11:03 am by Edvard
Everything is in modules/mod_gtranslate/tmpl/default.php and it is not alt attribute which appears when you hover. It is the title attribute. BTW. Which locale language do you use in Joomla?
Re: [GTranslate Pro / Joomla 1.5] alt-attribute / Flags
Dec 19, 2011 11:13 am by alt_f4
locale is "German (Germany-Switzerland-Austria)"
Re: [GTranslate Pro / Joomla 1.5] alt-attribute / Flags
Dec 19, 2011 11:54 am by Edvard
Can you try to change it to English and see if there is a difference?
Re: [GTranslate Pro / Joomla 1.5] alt-attribute / Flags
Dec 19, 2011 12:29 pm by alt_f4
no difference, but withe another template it works fine...seems to be a joomla/template problem. Same site, other template: http://new.imsware.de/ and it works. That solves it for me... Regards, alt_f4
Re: [GTranslate Pro / Joomla 1.5] alt-attribute / Flags
Dec 19, 2011 12:37 pm by Edvard
It is strange. I think you have template overrides in your problematic template. Check mod_gtranslate in your template html directory which I think does the override.
Re: [GTranslate Pro / Joomla 1.5] alt-attribute / Flags
Dec 20, 2011 7:48 am by alt_f4
Addendum: I've noticed a strange behavior: if the GTranslate cache is empty (all folders blank), the attribute is displayed correctly. But if GTranslate starts it´s job, next time the alt-attribute (yes, I know, it´s the title...) is wrong (is it possible, that it´s also translated by GTranslate)? Still strange... Regards, alt_f4
Re: [GTranslate Pro / Joomla 1.5] alt-attribute / Flags
Dec 20, 2011 10:42 am by alt_f4
Finally, after removing the Google-API and inserting a new BING-API key) I´ve deleted the wohle "cache" folder and uploaded a new, fresh one. Also deleted "limits.txt". Furthermore, I´ve created a new BING-API-key (but in config you write, that the "PHP SOAP client is required", I´m not sure if I´ve choosen the right one, but I just can´t find any alternative Bing-API-keys at http://www.bing.com/developers/createapp.aspx). All just related to the topic above, but the site doesn´t translate anymore. What´s on? My config.php: <?php define('API_KEY', ''); // You need to get your Google Translate API key from https://code.google.com/apis/console/?api=translate define('MAIN_LANG', 'de'); // en, ar, bg, hr, cn, ct, cs, da, et, tl, fi, fr, gl, el, iw, hi, es, nl, id, ja, ca, ko, lt, lv, mt, de, no, pt, ru, ro, sr, sk, sl, sv, th, tr, uk, hu, vi, it, pl, sq define('AUTO_DETECT_LANG', false); // set to true if you have mixed language content define('CACHE_TIME', 365*24*60*60); // 1 year by default, no need to decrease define('LICENSE', 'license.dat'); define('SSL_VERIFY_PEER', true); // disable if you get CA certificate error and cannot reconfigure your server to solve the issue define('FOLLOW_LOCATION', false); // if your site have redirects for some URLs and for that reason you see blank pages, you need to enable this feature define('USE_BING_TRANSLATOR', true); // Enable it to use Bing Translotor instead of Google Translate define('BING_API_KEY', 'BDAD75xxnotyoursxxxxx434E'); // If the option above is enabled you need to get your Bing API key from http://www.bing.com/developers/createapp.aspx (PHP SOAP client is required) define('DEBUG', false); // turn on for debug mode // username and password to edit translations, please change for security reasons, // this is not your google login/pass, you need to think something new define('USER', 'myuserishere'); define('PASS', 'mypassishere'); Best regards and once again thanks for your professional support! alt_f4
Re: [GTranslate Pro / Joomla 1.5] alt-attribute / Flags
Dec 20, 2011 11:34 am by Edvard
There was no need to delete the cache. If possible revert it back. May be German got translated into English? You can add <span>German</span> somewhere on your page and see if it is being translated into English when you change the language to English. If that happens then you can edit the translations and write a correct translation. Also, you can add class="notranslate" to the language selector wrapper element.
Re: [GTranslate Pro / Joomla 1.5] alt-attribute / Flags
Dec 20, 2011 12:24 pm by alt_f4
... May be German got translated into English? You can add <span>German</span> somewhere on your page and see if it is being translated into English when you change the language to English. If that happens then you can edit the translations and write a correct translation. ... Edvard, problem soveld with 5 stars...thanks again :mrgreen: Regards, alt_f4

SIMILAR TOPICS

Gtranslate MultisiteFeb 12, 2019 7:27 amReplies: 1Post by: infact_dat
Gtranslate: Error with numberFeb 20, 2019 1:20 amReplies: 1Post by: infact_dat
GTranslate 3.7.4, Joomla 3.9.3 - doGTranslate is not definedFeb 22, 2019 12:34 pmReplies: 1Post by: oase
Onloading the plugin quickly flashes up flags and text namesFeb 7, 2019 3:29 pmReplies: 1Post by: brobertson
Add-on gtranslate no longer worksFeb 2, 2019 6:01 amReplies: 1Post by: DarylDixon

Try GTranslate with a free 15 day trial