LinHES Forums http://forums.linhes.org/ |
|
0.16 - Mythweather in Mythweb http://forums.linhes.org/viewtopic.php?f=6&t=2532 |
Page 1 of 1 |
Author: | bgood4000 [ Tue Sep 28, 2004 5:11 pm ] |
Post subject: | 0.16 - Mythweather in Mythweb |
Cool! Mythweather is now accessible trough mythweb with 0.16. But all phrases begin with "_LANG_" as in _LANG_HUMIDITY, _LANG_PRESSURE, _LANG_WIND, etc. Also, temperatures are listed in F degrees while on my box it is set to display in C degrees. Anybody else has this kind of problem? BTW, mythweb is set to display its menu in french on the machine. [/img] |
Author: | tjc [ Tue Sep 28, 2004 5:44 pm ] |
Post subject: | |
Sounds like a missing resource somewhere in the French localization... It works OK in English so I don't think it's fundamental code problem. |
Author: | bgood4000 [ Wed Sep 29, 2004 10:43 pm ] |
Post subject: | |
putting it back in english fixed it. |
Author: | tjc [ Thu Sep 30, 2004 9:24 am ] |
Post subject: | |
But you really want it in French right? (Vous' et un Quebecois, non? (sorry, my French has rusted horribly after many years of neglect....)) This should be a configuration item in a (hopefully) external catalog file that you can fix with a bit of editing. |
Author: | bgood4000 [ Thu Sep 30, 2004 3:07 pm ] |
Post subject: | |
I give you 9.5 for your french exam. ![]() Editing /usr/share/mythtv/mythweb/config/conf.php and changing default language to french is the way I do it. Cause if you do it on the settings page of mythweb, it doenst stay. Is this the catalog file you are refering to? |
Author: | tjc [ Thu Sep 30, 2004 6:53 pm ] |
Post subject: | |
It sounded right in my head, but I knew it looked wrong... ![]() The catalog file is a different one that contains all the messages and prompts, ... basically all the text in the application. That way you have all the text that needs translation in one place. Hang on and let me hunt it down now that I'm home and have access to the KnoppMyth box... Ok, here's the session: Code: root@black:~ # find /usr/share/mythtv/mythweb -type f -print0 | xargs -0 grep -li humidity /usr/share/mythtv/mythweb/languages/English.php /usr/share/mythtv/mythweb/themes/Default/weather.php /usr/share/mythtv/mythweb/weather.php root@black:~ # ls -al /usr/share/mythtv/mythweb/languages/ total 104 drwxr-xr-x 2 mythtv mythtv 4096 Sep 24 22:00 . drwxr-xr-x 8 mythtv mythtv 4096 Sep 25 13:40 .. -rw-r--r-- 1 root root 15947 Sep 9 00:41 English.php -rw-r--r-- 1 root root 16219 Sep 9 00:41 French.php -rw-r--r-- 1 root root 14830 Sep 9 00:41 German.php -rw-r--r-- 1 root root 14684 Sep 9 00:41 Japanese.php -rw-r--r-- 1 root root 14785 Sep 9 00:41 Nederlands.php -rw-r--r-- 1 root root 14931 Sep 9 00:41 Swedish.php See the file /usr/share/mythtv/mythweb/languages/French.php? That's what you need to edit. Copy the following chunk of code from /usr/share/mythtv/mythweb/languages/English.php Code: /* weather.php */
define ('_LANG_HUMIDITY', 'Humidity'); define ('_LANG_PRESSURE', 'Pressure'); define ('_LANG_WIND', 'Wind'); define ('_LANG_VISIBILITY', 'Visibility'); define ('_LANG_WIND_CHILL', 'Wind Chill'); define ('_LANG_UV_INDEX', 'UV Index'); define ('_LANG_UV_MINIMAL', 'minimal'); define ('_LANG_UV_MODERATE', 'moderate'); define ('_LANG_UV_HIGH', 'high'); define ('_LANG_UV_EXTREME', 'extreme'); define ('_LANG_CURRENT_CONDITIONS', 'Current Conditions'); define ('_LANG_FORECAST', 'Forecast'); define ('_LANG_LAST_UPDATED', 'Last Updated'); define ('_LANG_HIGH', 'High'); define ('_LANG_LOW', 'Low'); define ('_LANG_UNKNOWN', 'Unknown'); define ('_LANG_RADAR', 'Radar'); define ('_LANG_AT', 'at'); define ('_LANG_TODAY', 'Today'); define ('_LANG_TOMORROW', 'Tomorrow'); define ('_LANG_MONDAY', 'Monday'); define ('_LANG_TUESDAY', 'Tuesday'); define ('_LANG_WEDNESDAY', 'Wednesday'); define ('_LANG_THURSDAY', 'Thursday'); define ('_LANG_FRIDAY', 'Friday'); define ('_LANG_SATURDAY', 'Saturday'); define ('_LANG_SUNDAY', 'Sunday'); into the file right above the line that says /* utils.php */ and make the appropriate translations. Finally, go to the MythTv bugzilla at http://www.mythtv.org/bugs/ and file an item for the missing translation. Don't forget to paste your corrected block of code into the bug report so that they can use it. ![]() |
Author: | bgood4000 [ Fri Oct 01, 2004 5:19 pm ] |
Post subject: | |
Thanks. It looks a lot better now. ![]() I also fixed a few other things in the french.php file. A few entries still needed translation, and the entry for ¨Manually Schedule Recordings¨ was completely missing. Opened up an account on Bugzilla, filed a bug report and gave them the modified code. Thanks again. |
Author: | tjc [ Fri Oct 01, 2004 11:14 pm ] |
Post subject: | |
bgood4000 wrote: I also fixed a few other things in the french.php file. ... ... Opened up an account on Bugzilla, filed a bug report and gave them the modified code.
Thanks again. Heck! Thank you for actually taking the time to do it! ![]() |
Page 1 of 1 | All times are UTC - 6 hours |
Powered by phpBB® Forum Software © phpBB Group http://www.phpbb.com/ |