17 votes
Accepted

How to manage language variables inside JavaScript?

Joomla has a certain method for this. First, in view.html.php add all strings, what needs to be translated with this: JText::script('VALIDATION_ERROR'); This will add your string to javascript ...
Rene Korss's user avatar
  • 3,208
6 votes
Accepted

JText - multilingual string order

Add further abstraction. JText::sprintf('COM_MYCOMPONENT_DATETIME_AGO', $num, JText::_('SHOUT_TIME'), JText::_('SHOUT_AGO')); English language COM_MYCOMPONENT_DATETIME_AGO="%1$s %2$s %3$s" German ...
Nagarjun's user avatar
  • 2,991
6 votes
Accepted

How to adjust search keyword sanitization settings as language override?

Look for methods called set<PROPERTY>Callback on the same API documentation you linked. E.g. to override the lower limit use Joomla\CMS\Language\Language::setLowerLimitSearchWordCallback(). I'm ...
Sharky's user avatar
  • 11.1k
5 votes
Accepted

Joomla 3.9 not reading language override strings for English only

I was not able to duplicate your issue. I used the Joomla core Beez3 template to test this, where the template by default has the language files in main (Joomla root) Language folder and at the same ...
Zollie's user avatar
  • 2,936
4 votes
Accepted

Module title not getting from language file

The problem is I need to keep the language files inside en-GB folder <languages> <language tag="en-GB">language/en-GB/en-GB.mod_quickwrk.ini</language> <language tag="en-GB"...
Malaiselvan's user avatar
  • 2,731
4 votes
Accepted

Language files in a plugin

Since Joomla 3.1 it is not necessary to expand the constructor any more, like farahmand's answer. You can easily write / set the $autoloadLanguage like class myPlugin extends JPlugin { /** *...
Tom Kuschel's user avatar
4 votes
Accepted

Updating component language file without reinstalling it

The language files are loaded again (from their source) on each page load. You don't need to reinstall the component each time. Are you writing to the right file?
Hackwar's user avatar
  • 156
4 votes
Accepted

Remove 'There are no articles in this category.' Text

Got to; content > articles > options > category tab > No Articles Message > hide / show
TheOrdinaryGeek's user avatar
4 votes
Accepted

language file naming conventions

Use non-prefixed filenames in J4 (3.10 also supports this). Nothing is stripping the prefix, some core manifest files just haven't been updated.
Sharky's user avatar
  • 11.1k
3 votes
Accepted

Save in logs files changes of Language Manager

Usually you would use "onContentBeforeSave" function of content-type plugin, but for some reason com_languages doesn't launch "onContentBeforeSave" and "onContentAfterSave" events. However there is ...
Krossfire's user avatar
3 votes
Accepted

How to rewrite JText to get my custom text translations from Database and not from files

Instead of overwriting or modifying the JText class why not just write a function call function in your model that retrieves your translation from the database and return the string? Echo the string ...
Terry Carter's user avatar
  • 1,812
3 votes

Joomla 3.4.4 - URL Problems with alias of products in submenu

I FOUND THE SOLUTION!!! Temporary change menu item type to Text Separator, modify alias to your liking and change type back to External URL. REFERENCE:http://www.mysysadmintips.com/other/web/...
Gabriel91's user avatar
  • 223
3 votes

Remove language code from url

As far as I know what you want isn't possible. The /en/ is needed so Joomla knows that you want to change the language. Because with www.example.com/company/contact.html Joomla would look in your ...
Bakual's user avatar
  • 5,582
3 votes
Accepted

How to add a language pack (or language specific string overrides) to a template?

There are a couple of ways to deal with this. 1. Create a German language ini file for your template. a. Go to languages folder -> EN-GB b. Spot your template's EN-GB language file: e.g. en-GB....
FFrewin's user avatar
  • 19.7k
3 votes

Language files in a plugin

Load the language files in the plugin's constructor like so: function __construct(&$subject, $config) { $lang = JFactory::getLanguage(); $lang->load('plg_system_myplugin', dirname(...
Farahmand's user avatar
  • 2,295
3 votes
Accepted

Home page a mix of language

This is the title of the Module - that is hand-written and editable. You can write anything you want on it. If you go to the Modules' Manager, you will be able to find this module - click to edit it ...
FFrewin's user avatar
  • 19.7k
3 votes
Accepted

Export language overrides

Like all languages strings, overrides are stored in .ini files in language directories: /administrator/language/overrides/ /language/overrides/
Sharky's user avatar
  • 11.1k
3 votes
Accepted

Load language file in view constructor

JROOT is not a valid path constant. Change it to JPATH_ROOT. Or use JPATH_ADMINISTRATOR instead of JROOT . DS . 'administrator'
Sharky's user avatar
  • 11.1k
3 votes
Accepted

Using language constants in external file

Your language files are not loaded. Load them with Joomla\CMS\Language\Language::load(). This example loads administrator/language/en-GB/en-GB.com_content.ini file: $app = JFactory::getApplication('...
Sharky's user avatar
  • 11.1k
2 votes

Getting current language in Joomla 3 in external script seems difficult.. but works fine in J2.5

I use the default Joomla multilingual management, no falang, no third-party plugin. Same problem, and I spent 1 hour to find the solution. The key is, don't try to use JFactory::getLanguage(). ...
user11516's user avatar
2 votes

Add text to registration form

You can find this string in this file - /components/com_users/models/forms/registration.xml I hope it will help you :)
Joomler's user avatar
  • 1,811
2 votes

Module title not getting from language file

The proper method is like follows, In your module's xml file it should have language file like follows: <languages> <language tag="en-GB">en-GB.mod_latesttweets.ini</language&...
Nehal's user avatar
  • 293
2 votes

Localization Questions

Joomla does not support country-specific variant files. Even with British-English and American English, there are different files: en-GB en-US They way Joomla works with it's language strings is, ...
Lodder's user avatar
  • 26.9k
2 votes

Joomla 3.4.8 language filter "Automatic Language Change" disabled but still redirects in some cases

Blame Google my man! That's the biggest sniffer in the world, and I bet you any money that due to the fact your site is alive for a few months, it found Swedish articles on it's own and without your ...
Mikan's user avatar
  • 3,007
2 votes
Accepted

Component language file is coppied but does not work

You can also ship the language files within your component in the language folder as I do with DPFields https://github.com/Digital-Peak/DPFields/blob/master/com_dpfields/admin/dpfields.xml#L48. After ...
Laoneo's user avatar
  • 503
2 votes

Component language file is coppied but does not work

Try this: <languages folder="admin"> <language tag="en-GB">language/en-GB/en-GB.com_displaygroups.sys.ini</language> </languages> and remove <folder>language</...
Terry Carter's user avatar
  • 1,812
2 votes
Accepted

No available languages to install at the moment

I didn't spend more time to find the cause and the fix of this issue back then, but today I had to work on a site with the same issue: No Languages Available on the Languages Manager and a requirement ...
FFrewin's user avatar
  • 19.7k
2 votes
Accepted

joomla 3.6 admin language won't change

Perhaps you've set the default admin language for your own user. Alter this setting for your user by going to your site's administration and go to users > manage > choose your user > basic settings ...
Wim de Ruijter's user avatar
2 votes

How to add a language pack (or language specific string overrides) to a template?

So, in my case it was that the strings were hard-coded into the template through the inclusion of a single language pack in the template language folder for English. What I did was to create my own ...
nizz0k's user avatar
  • 537
2 votes

Language files in a plugin

I assume you have done the following, but just to make sure: read https://docs.joomla.org/Creating_a_profile_plugin/en be sure the language file exists and in the right folder (double)check the ...
YolkNet's user avatar
  • 81

Only top scored, non community-wiki answers of a minimum length are eligible