Location of template language files: Difference between revisions
From Joomla! Documentation
New page: Language definition files for front-end templates are stored in <nowiki>[path-to-Joomla]/language/[ln-LN]</nowiki> where ''<nowiki>[ln-LN]</nowiki>'' is the language code. Language code... |
Corrected the RFC3066 URL. |
||
| (9 intermediate revisions by 3 users not shown) | |||
| Line 1: | Line 1: | ||
Language definition files for front-end templates are stored in | <noinclude><languages /></noinclude> | ||
<translate><!--T:1--> | |||
Language definition files for front-end templates are stored in</translate> | |||
<nowiki>[path-to-Joomla]/language/[ln-LN]</nowiki> | <nowiki>[path-to-Joomla]/language/[ln-LN]</nowiki> | ||
where ''<nowiki>[ln-LN]</nowiki>'' is the language code. Language codes are defined in RFC3066<ref name="ftn1"> | <translate> | ||
<!--T:2--> | |||
where ''<nowiki>[ln-LN]</nowiki>'' is the language code. Language codes are defined in RFC3066<ref name="ftn1">[https://www.ietf.org/rfc/rfc3066.txt RFC3066: Tags for the Identification of Languages]</ref> The file must be named | |||
</translate> | |||
<nowiki>[ln-LN].tpl_[template-name].ini</nowiki> | <nowiki>[ln-LN].tpl_[template-name].ini</nowiki> | ||
<translate> | |||
<!--T:3--> | |||
where ''<nowiki>[template-name]</nowiki>'' is the name of the template (in lowercase). For example, the British English language file for the Beez template is | where ''<nowiki>[template-name]</nowiki>'' is the name of the template (in lowercase). For example, the British English language file for the Beez template is | ||
</translate> | |||
<nowiki>[path-to-Joomla]/language/en-GB/en-GB.tpl_beez.ini</nowiki> | <nowiki>[path-to-Joomla]/language/en-GB/en-GB.tpl_beez.ini</nowiki> | ||
<translate> | |||
<!--T:4--> | |||
You should also create a separate language file for translating the Administrator back-end of your template. This will be stored in | You should also create a separate language file for translating the Administrator back-end of your template. This will be stored in | ||
</translate> | |||
<nowiki>[path-to-Joomla]/administrator/language/[ln-LN]</nowiki> | <nowiki>[path-to-Joomla]/administrator/language/[ln-LN]</nowiki> | ||
<translate> | |||
<!--T:5--> | |||
but the file naming convention is the same. | but the file naming convention is the same. | ||
<!--T:6--> | |||
For administrator templates, as distinct from front-end templates, the second of these files is the only one required. For example, the British English language file for the Khepri administrator template is located in | For administrator templates, as distinct from front-end templates, the second of these files is the only one required. For example, the British English language file for the Khepri administrator template is located in | ||
</translate> | |||
<nowiki>[path-to-Joomla]/administrator/language/en-GB/en-GB.tpl_khepri.ini</nowiki> | <nowiki>[path-to-Joomla]/administrator/language/en-GB/en-GB.tpl_khepri.ini</nowiki> | ||
<noinclude> | |||
---- | ---- | ||
<references/> | <references/> | ||
<translate> | |||
<!--T:7--> | |||
[[Category:Templates]] | |||
[[Category:Languages]] | |||
</translate> | |||
</noinclude> | |||
Latest revision as of 20:27, 15 July 2022
Language definition files for front-end templates are stored in
[path-to-Joomla]/language/[ln-LN]
where [ln-LN] is the language code. Language codes are defined in RFC3066[1] The file must be named
[ln-LN].tpl_[template-name].ini
where [template-name] is the name of the template (in lowercase). For example, the British English language file for the Beez template is
[path-to-Joomla]/language/en-GB/en-GB.tpl_beez.ini
You should also create a separate language file for translating the Administrator back-end of your template. This will be stored in
[path-to-Joomla]/administrator/language/[ln-LN]
but the file naming convention is the same.
For administrator templates, as distinct from front-end templates, the second of these files is the only one required. For example, the British English language file for the Khepri administrator template is located in
[path-to-Joomla]/administrator/language/en-GB/en-GB.tpl_khepri.ini