Bulding Extension's Language Pack for J1.5
Moderator: wendhausen
- sifix
- Joomla! Fledgling
- Posts: 4
- Joined: Mon Aug 07, 2006 2:41 pm
- Location: Athens - Greece
Bulding Extension's Language Pack for J1.5
Hallo,
I am trying to create an component extension for Joomla 1.5 and I havequestions regarding language packs.
Are there any insructions on how to combine a language pack with the extension?
I use the JText::_( 'NAME' ); but I don't know where to put my language file
I tried the following but it didn't work.
I create a file en-GB.com_mycomp.ini and placed it in \language\en-GB (both in admin and frond area)
NAME=the name is
but unfortunately joomla did not read my ini file
So instead of displaying "the name is" it displays "NAME"
I don't know if the above method is correct or I do something wrong,
I am sorry for bothering but the section with How-to's is still empty ( http://dev.joomla.org/component/option, ... languages/ )
I would appreciate if you could help me
Thank you very much
I am sorry I found what I did wrong.. It had nothing to do with the above.
The above are correct
As also is mentioned here
http://forum.joomla.org/index.php/topic ... #msg432913
Keep on the good work..
I am trying to create an component extension for Joomla 1.5 and I havequestions regarding language packs.
Are there any insructions on how to combine a language pack with the extension?
I use the JText::_( 'NAME' ); but I don't know where to put my language file
I tried the following but it didn't work.
I create a file en-GB.com_mycomp.ini and placed it in \language\en-GB (both in admin and frond area)
NAME=the name is
but unfortunately joomla did not read my ini file
So instead of displaying "the name is" it displays "NAME"
I don't know if the above method is correct or I do something wrong,
I am sorry for bothering but the section with How-to's is still empty ( http://dev.joomla.org/component/option, ... languages/ )
I would appreciate if you could help me
Thank you very much
I am sorry I found what I did wrong.. It had nothing to do with the above.
The above are correct
As also is mentioned here
http://forum.joomla.org/index.php/topic ... #msg432913
Keep on the good work..
Last edited by sifix on Wed Aug 23, 2006 3:33 pm, edited 1 time in total.
- davidgal
- Joomla! Guru
- Posts: 963
- Joined: Sat Aug 20, 2005 9:19 am
- Location: Israel
- Contact:
Re: Bulding Extension's Language Pack for J1.5
Hi,
In your installation xml you need a tag group for site language packs and for admin packs.
each language file should be enclosed in a tag and should have the sub folder of the specific language included i.e 'fr-FR/fr-FR.com_mycomponent.ini'
The concept is that any language pack inside the component installation package will be added to existing language folders for each language. If there is no core language installed the file will be discarded. It is also possible to create separate language packs for later installation to existing (installed) components. These install like regular language packs but without the metadata xml and with out the 'core' flag in the installation xml file.
I will be created the language spec doumentation in the near future. In the mean time I hope that this helps.
David
In your installation xml you need a tag group for site language packs and for admin packs.
each language file should be enclosed in a tag and should have the sub folder of the specific language included i.e 'fr-FR/fr-FR.com_mycomponent.ini'
The concept is that any language pack inside the component installation package will be added to existing language folders for each language. If there is no core language installed the file will be discarded. It is also possible to create separate language packs for later installation to existing (installed) components. These install like regular language packs but without the metadata xml and with out the 'core' flag in the installation xml file.
I will be created the language spec doumentation in the near future. In the mean time I hope that this helps.
David
David Gal
- eyezberg
- Joomla! Hero
- Posts: 2859
- Joined: Thu Aug 25, 2005 5:48 pm
- Location: Geneva mostly
- Contact:
Re: Bulding Extension's Language Pack for J1.5
This
is WAY cool!! Great news! Beta beta beta ...davidgal wrote: ...It is also possible to create separate language packs for later installation to existing (installed) components. These install like regular language packs but without the metadata xml and with out the 'core' flag in the installation xml file....
David
Sometimes one pays most for the things one gets for nothing.
The important thing is not to stop questioning. Curiosity has its own reason for existing. AE
http://joomla15.[URL banned].com for J! 1.5 screenshots
http://www.eyezberg.com
The important thing is not to stop questioning. Curiosity has its own reason for existing. AE
http://joomla15.[URL banned].com for J! 1.5 screenshots
http://www.eyezberg.com
- sakiss
- Joomla! Explorer
- Posts: 349
- Joined: Wed Aug 20, 2008 4:09 pm
Re: Bulding Extension's Language Pack for J1.5
That means that you can install the language ini file imediatelly from joomla backend ?
Should other files being contained with the language ini file (ex. a zip with ini and xml)?
Should other files being contained with the language ini file (ex. a zip with ini and xml)?
- Eraser
- Joomla! Enthusiast
- Posts: 176
- Joined: Sat Aug 20, 2005 10:58 am
- Location: Estonia
- Contact:
Re: Bulding Extension's Language Pack for J1.5
Yep, language files of the component/module/plugin can be installed with the Joomlas installer.sakiss wrote:That means that you can install the language ini file imediatelly from joomla backend ?
Should other files being contained with the language ini file (ex. a zip with ini and xml)?
You can do it automatically with different automatic components like Language Manager. But You can do it by hand also.
In a zip file there need to be files like that:
et-EE-zoo-10.zip
- admin (folder)
- et-EE.com_zoo.ini
- site (folder)
- et-EE.com_zoo.ini
- install.xml
Content of the install.xml file should be looking something like that:
Code: Select all
<?xml version="1.0" encoding="utf-8"?>
<install version="1.5" client="both" type="language" method="upgrade">
<name>Zoo Estonian (Eesti)</name>
<tag>et-EE</tag>
<version>2.0.2</version>
<creationDate>2009-04-02</creationDate>
<author>Eraser</author>
<authorEmail>[email protected]</authorEmail>
<authorUrl>www.eraser.ee</authorUrl>
<copyright>(C) 2005 - 2009 Eraser. All rights reserved.</copyright>
<license>http://www.gnu.org/licenses/gpl-2.0.html GNU/GPL</license>
<description>Estonian translation for Zoo 1.0.3 Site and Admin (Joomla! 1.5.x)</description>
<administration>
<files folder="admin">
<filename>et-EE.com_zoo.ini</filename>
</files>
</administration>
<site>
<files folder="site">
<filename>et-EE.com_zoo.ini</filename>
</files>
</site>
<params />
</install>
You can find the file i show as an example here from this url. Download it and learn from this example.
Estonian Translation Team - http://www.eraser.ee
- sakiss
- Joomla! Explorer
- Posts: 349
- Joined: Wed Aug 20, 2008 4:09 pm
Re: Bulding Extension's Language Pack for J1.5
Man i really thank you
- foto50
- Joomla! Apprentice
- Posts: 12
- Joined: Mon May 14, 2007 9:47 am
Re: Bulding Extension's Language Pack for J1.5
Thanks as well, I now can provide extra language packages for my component without having to zip (and xml) them into the entire install.xml.
I had to try quite a bit to get that running for a module and thought, my solution might help others to avoid searching and trying:
Since the module does not have any files for <administration> I thought, it's good enough just to delete this section, but DONT!
When there is no language file for administration, you need to keep an empty node for it in the install.xml! Like:The <administration /> is the important line for it. Otherwise you get errors like:
I hope this helps one or the other
Greetz
FoTo50
I had to try quite a bit to get that running for a module and thought, my solution might help others to avoid searching and trying:
Since the module does not have any files for <administration> I thought, it's good enough just to delete this section, but DONT!
When there is no language file for administration, you need to keep an empty node for it in the install.xml! Like:
Code: Select all
<?xml version="1.0" encoding="utf-8"?>
<install version="1.5" client="both" type="language" method="upgrade">
<name>mod_opensim_friends english</name>
<tag>en-GB</tag>
<version>0.1.7</version>
<creationDate>2010-11-30</creationDate>
<author>FoTo50</author>
<authorEmail>blabla email</authorEmail>
<authorUrl>blabla website</authorUrl>
<copyright>(C) 2010 FoTo50. All rights reserved.</copyright>
<license>http://www.gnu.org/licenses/gpl-2.0.html GNU/GPL</license>
<description>English translation for mod_opensim_friends Site and Admin (Joomla! 1.5.x)</description>
<administration />
<site>
<files folder="site">
<filename>en-GB.mod_opensim_friends.ini</filename>
</files>
</site>
<params />
</install>
Code: Select all
PHP Fatal error: Call to a member function getElementByPath() on a non-object in /some.joomla.path/libraries/joomla/installer/adapters/language.php on line 70
Greetz
FoTo50
- Eraser
- Joomla! Enthusiast
- Posts: 176
- Joined: Sat Aug 20, 2005 10:58 am
- Location: Estonia
- Contact:
Re: Bulding Extension's Language Pack for J1.5
And of course - same goes for the frontend (site) files also ...
Estonian Translation Team - http://www.eraser.ee
-
- Joomla! Apprentice
- Posts: 5
- Joined: Tue Dec 13, 2011 3:32 pm
- Location: Canada
- Contact:
Re: Bulding Extension's Language Pack for J1.5
really well explained. great work and thank you so much!foto50 wrote:Thanks as well, I now can provide extra language packages for my component without having to zip (and xml) them into the entire install.xml.
I had to try quite a bit to get that running for a module and thought, my solution might help others to avoid searching and trying:
Since the module does not have any files for <administration> I thought, it's good enough just to delete this section, but DONT!
When there is no language file for administration, you need to keep an empty node for it in the install.xml! Like:The <administration /> is the important line for it. Otherwise you get errors like:Code: Select all
<?xml version="1.0" encoding="utf-8"?> <install version="1.5" client="both" type="language" method="upgrade"> <name>mod_opensim_friends english</name> <tag>en-GB</tag> <version>0.1.7</version> <creationDate>2010-11-30</creationDate> <author>FoTo50</author> <authorEmail>blabla email</authorEmail> <authorUrl>blabla website</authorUrl> <copyright>(C) 2010 FoTo50. All rights reserved.</copyright> <license>http://www.gnu.org/licenses/gpl-2.0.html GNU/GPL</license> <description>English translation for mod_opensim_friends Site and Admin (Joomla! 1.5.x)</description> <administration /> <site> <files folder="site"> <filename>en-GB.mod_opensim_friends.ini</filename> </files> </site> <params /> </install>
I hope this helps one or the otherCode: Select all
PHP Fatal error: Call to a member function getElementByPath() on a non-object in /some.joomla.path/libraries/joomla/installer/adapters/language.php on line 70
Greetz
FoTo50
served me well and somewhat saved my weekend..