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 viewforum.php?f=614 instead <<
Forum rules
Please use the Forum Post Assistant to give your server setting details which are necessary to determine the problem.
Sk0pe
Joomla! Apprentice
Joomla! Apprentice
Posts: 20
Joined: Wed Nov 08, 2006 12:16 pm

Language overrides

Postby 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

Postby 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

Postby 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! Intern
Joomla! Intern
Posts: 84
Joined: Sun Dec 28, 2008 3:25 pm
Location: Sweden
Contact:

Re: Language overrides

Postby formfranska » Tue Apr 19, 2011 7:41 pm

Thank you rufuz! It works fine :-)

Greetings
Anna
Joomlare in Sweden :-)
http://www.formfranska.com


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

Who is online

Users browsing this forum: No registered users and 2 guests