-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Custom language files #232
Comments
Custom language files could be:
or
@tablatronix (and anyone else) Which way do you think it's better? Do you think it would be interesting to implement this also in GS? |
So this would be an ancillary override file for all language tokens. Merge after all langs are loaded, this might be problematic in that plugins can load their languages whenever or however they want. Might not be able to override it always, We might have to modify i18n functions to check these overrides in real time. |
I'm not suggesting that GS does the merge for plugins. It would be only for the core language. The way I was thinking about this, if a plugin wants to support this it would have to do the merge itself (like I intend to do in NM) |
hmm, I can see one issue I guess the question is what are you satisfying , users wanting custom wording or more specific wording on a token. or missing token handling, or something else? |
Normally you would just override some definitions, e.g. changing the plugin sidebar title to just "News" or "Blog" (instead of "News Manager"), or using the word "article" instead of "post" in several strings... Also redefining LOCALE, frontend strings... I'd like to know which method of the two you think would be better, |
I think that the meaning of the strings in a language file should not have big changes. |
yeah this would be pretty nice for core... was trying to figure out how to implement though. What really sucks is that these files should probably be outside of plugins and lang, I proposed a data/langs location on github somewhere. I think a subfolder works better for making any get langs calls easier to fix ( dont have to filter by filenames ), also you don't need special names for files, you can just use paths or symblinks etc. |
Thanks, I'll probably go the subfolder way ( |
Leaving this for later. |
Add support for optional custom language files, which can be full (including all string definitions, like the normal language files) or partial (including just some strings). Same structure as the normal language file: an $18n array that would be merged after loading the normal lang file.
This way users could update the plugin (or updating some language file) by just overwriting all files, without worrying about any modifications in language files.
The text was updated successfully, but these errors were encountered: