https___docs.joomla.org_Loading_extra_language_files.xml
http___forum.joomla.hr_index.php_topic_3945.msg13135_1.xml
1.1 2.1 2.2 3.1 4.1 4.2 4.3 4.4 5.1 6.1 7.1 8.1 9.1 10.1 11.1 12.1 13.1 14.1 14.2 14.3 15.1 15.2 16.1 16.2 17.1 17.2 17.3 17.4 18.1 18.2
Loading extra language files From Joomla! Documentation Overview Many times, you need to load extra language files in your code. An example is loading your component's language file into a module for that component. This example loads a single language file, and appends the results to the existing language strings. Following is the code that helps you do this PHP Code $lang = JFactory::getLanguage(); $extension = 'com_helloworld'; $base_dir = JPATH_SITE; $language_tag = 'en-GB'; $reload = true; $lang->load($extension, $base_dir, $language_tag, $reload); Following is an explanation of the variables $extension - This is the extension whose language file will be loaded $base_dir - Should be JPATH_SITE in case you have language files stored elsewhere. Defaults to JPATH_BASE. [optional] Note: Joomla will look in its /languages/ folder for a en-GB.com_helloworld.ini language file. If you put your component's language file in your own components language folder /components/com_helloworld/language/en-GB/en-GB.com_helloworld.ini, then you need to specify the path: $base_dir = JPATH_SITE . '/components/com_helloworld' $language_tag - This is the locale string. Language files for this locale will be loaded. Defaults to the one set in backend. [optional] $reload - Flag that will force a language to be reloaded if set to true. [optional]
1.1 2.1 3.1 3.2 4.1 5.1 6.1 7.1 8.1 9.1 10.1 12.1 12.2
Ja na takve stvari ne gubim vrijeme s pronalaženjem već problem zaobiđem na način na koji mora radit.... Nađeš fino gdje se dotični Readmore ispisuje (jer bogtepitaj iz koje language datoteke na kraju vuče taj readmore) i napraviš slijedeće: 1. napraviš si u language/xx-xx/xx-xx.custom.ini i u njega staviš svoje konstante (npr. CUSTOM_READMORE="Više.......") 2. u datoteci u kojoj hoćeš ispisati "svoj" readmore napraviš slijedeće: nakon linije koja izgleda otprilike ovako defined('_JEXEC') or die; ubaciš $language =& JFactory::getLanguage(); $language->load('custom' , JPATH_SITE, $language->getTag(), true); 3. na mjestu gdje hoćeš ispisat svoj izraz Na taj način si siguran da će ovdje uzet baš tvoj prijevod... K2 je nekad imao velikih problema s ovim jer je isti izraz bio po više datoteka i naravno - uzeo je iz krive