Actions

J2.5 talk

Difference between revisions of "Developing a MVC Component/Adding language management"

From Joomla! Documentation

(New page: There also needs to be a language translation for the ADMIN Menu. Otherwise, the admin menu will only show the menu-item aliases [http://forum.joomla.org/viewtopic.php?f=579&t=537438 See F...)
 

Revision as of 11:34, 17 December 2011

There also needs to be a language translation for the ADMIN Menu. Otherwise, the admin menu will only show the menu-item aliases See Forum thread.

The specification of the admin menu for the component in the installation manifest would look something like this:

<menu>com_hello</menu>
<submenu>
        <menu controller="features">com_hello_greetings</menu>
        <menu controller="config">com_hello_config</menu>
</submenu>

Then we would add an additional language file to the installation manifest called en-GB.com_hello.sys.ini:

<languages folder="admin">
       <language tag="en-GB">language/en-GB/en-GB.com_helloworld.ini</language>
       <language tag="en-GB">language/en-GB/en-GB.com_helloworld.menu.ini</language>
       <language tag="en-GB">language/en-GB/en-GB.com_helloworld.sys.ini</language>
</languages>

And this new language file would look like this:

COM_HELLO=Hello World!
COM_HELLO_GREETINGS=Manage Greetings
COM_HELLO_CONFIG=Configuration