?
avatar horus68
horus68
30 Jul 2020

Problem identified

Language values (all Joomla versions) shows some terms surrounded by colons (:)
as in

JFolder: :delete: Path is not a folder. Path: %s
JLIB_FILESYSTEM_ERROR_PATH_IS_NOT_A_FOLDER
File: en-GB.lib_joomla.ini

JFolder: :files: Path is not a folder. Path: %s
JLIB_FILESYSTEM_ERROR_PATH_IS_NOT_A_FOLDER_FILES
File: en-GB.lib_joomla.ini


JFolder: :folder: Path is not a folder. Path: %s
JLIB_FILESYSTEM_ERROR_PATH_IS_NOT_A_FOLDER_FOLDER
File: lib_joomla.ini

JFolder: :files: Path is not a folder. Path: %s
JLIB_FILESYSTEM_ERROR_PATH_IS_NOT_A_FOLDER_FILES
File: en-GB.ini

Are those of to be translated? Are they placeholders? Or just technical terms (as in method names)?

Proposed solution

It should be clear for translators if they can be or not translated.
If they are to be translated maybe the sentences could be in better english (not my field as I'm not a proper english speaker!)

avatar horus68 horus68 - open - 30 Jul 2020
avatar joomla-cms-bot joomla-cms-bot - change - 30 Jul 2020
Labels Added: ?
avatar joomla-cms-bot joomla-cms-bot - labeled - 30 Jul 2020
avatar horus68 horus68 - change - 30 Jul 2020
The description was changed
avatar horus68 horus68 - edited - 30 Jul 2020
avatar horus68 horus68 - change - 30 Jul 2020
The description was changed
avatar horus68 horus68 - edited - 30 Jul 2020
avatar chmst
chmst - comment - 30 Jul 2020

These strings are method names and may not be translated. It is a good idea to make this clear for translators in the doc block. I let this for a native speaker.


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/30234.

avatar SharkyKZ
SharkyKZ - comment - 30 Jul 2020

Ideally classes and methods should be passed as variables instead of being hardcoded in language strings.

avatar chmst
chmst - comment - 1 Aug 2020

Also classes and methods? They will not change, are not dependent on the context. So I think that hard coded language strings are all right. Otherwise the scripts must be changed.


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/30234.

avatar brianteeman
brianteeman - comment - 1 Aug 2020

@chmst I am assuming that @SharkyKZ means that it should be

The class %s could not be found

instead of

the class jbrian could not be found

avatar chmst
chmst - comment - 1 Aug 2020

@brianteeman maybe I understood this wrong

Someone uses in a script: i.e. $tmp = JFolder::folder('jbrian');

The message is now: JFolder: :folder: Path is not a folder. Path: jbrian

A better message could be: JFolder :folder: could not find the path 'jbrian'

Class and Method (here JFolder :: folder ) are an important information, but kind of constant and think they must not be variables and cannot be translated

avatar infograf768
infograf768 - comment - 2 Aug 2020

Good luck for whoever decides to make a PR using hardcoded stuff.
In lib.joomla.ini, we have 139 occurrences of : : + 3 in installation ini

These corresponds to various methods which should provide the hardcoded part.
It is not only JFolder: :folder or JFolder: :files but JInstaller, JFTP, JApplication, JModel, JView, etc. etc.

avatar chmst
chmst - comment - 2 Aug 2020

As many class names have changed with namespacing, this could indeed be a challenge.

avatar PhilETaylor
PhilETaylor - comment - 2 Aug 2020

Class and Method (here JFolder :: folder ) are an important information

I would say to remove them all !!

A USER seeing an error/warning notice doesn't need to know it comes from JFolder class or JFile class, they just need to know the message.

JFolder\JFile class names are of no use whatsoever to the end user.

avatar brianteeman
brianteeman - comment - 25 Nov 2020

This should be closed as @Bakual is working through these

avatar Quy Quy - change - 25 Nov 2020
Status New Closed
Closed_Date 0000-00-00 00:00:00 2020-11-25 16:09:49
Closed_By Quy
avatar Quy Quy - close - 25 Nov 2020

Add a Comment

Login with GitHub to post a comment