Language overrides

This board for support questions on Joomla 1.6 RC (= Release Candidate - which should NOT be used on a production server) is NO longer active because Joomla 1.6.0 has been released.

>> For Joomla! 1.6 Support Questions, please use http://forum.joomla.org/viewforum.php?f=614 instead <<
Locked
Sk0pe
Joomla! Apprentice
Joomla! Apprentice
Posts: 20
Joined: Wed Nov 08, 2006 12:16 pm

Language overrides

Post by Sk0pe » Thu Dec 02, 2010 1:27 am

Hi There,

I have been playing with J! 1.6 (b14 atm) and so far all looks really really nice.

I have one question however, regarding overriding the default text with language files. One thing I have loved about J! is the layout overrides, but it has often frustrated me that language files are not treated is the same way.

I notice that in the J! 1.6 structure, there is a folder /language/overrides and I am trying to work out exactly how it functions. For example, I want to change the default text for mod_login, so I have copied /language/en-GB/en-GB.mod_login.ini into the override folder, and then made modifications. However these changes do not seem to have taken. I also created the folder /language/overrides/en-GB and put the modified language file in there, but it does not seem to be changing the text in the front end.

Can anyone explain how the language override structure is supposed to work? How can I make small changes like changing MOD_LOGIN_HINAME to be "Logged in as %s" instead of "Hi %s" ?

Thanks,

Micha

User avatar
rufuz
Joomla! Explorer
Joomla! Explorer
Posts: 303
Joined: Wed May 09, 2007 10:07 am
Location: Rome
Contact:

Re: Language overrides

Post by rufuz » Fri Dec 03, 2010 12:52 am

I did something like that just creating a file named en-GB.override.ini inside language/overrides folder. Put in it the whole strings you need to change. It should work.

ricc.

Sk0pe
Joomla! Apprentice
Joomla! Apprentice
Posts: 20
Joined: Wed Nov 08, 2006 12:16 pm

Re: Language overrides

Post by Sk0pe » Fri Dec 03, 2010 1:33 am

I saw that in the language.php class file. I think it would be worthwhile allowing individual override files on a per-extension basis. It could be done in the JLanguage::loadLanguage() function fairly easily. Replace the override processing in JLanguage::__construct() with simply setting an override path. Then use that path in the loadLanguage() function to load and merge an extension specific override file after you have merged the default extension specific language file.

The issue with a single override file is that it makes automated processing of the language overrides difficult. Consider language overrides in a similar way to layout overrides. They are more than simply translation mechanisms - they also allow a change to the whole tone of the site, through formal, colloquial, or artificial language.

User avatar
formfranska
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 177
Joined: Sun Dec 28, 2008 3:25 pm
Location: Sweden
Contact:

Re: Language overrides

Post by formfranska » Tue Apr 19, 2011 7:41 pm

Thank you rufuz! It works fine :-)

Greetings
Anna
Joomler in Sweden :-)
https://www.formfranska.com


Locked

Return to “Joomla! 1.6 RC Support [closed]”