Skip to content
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

i18n implement #1259

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open

i18n implement #1259

wants to merge 4 commits into from

Conversation

benfre
Copy link

@benfre benfre commented Nov 28, 2022

I implemented a naive i18n() function.
I am not expecting it to merge immediately.I didn't know enough of php and js, so there lack of configuration and user choice. Help is needed. But for anyone interested in using this patch as it is, it can translate user interface to another language. For now only zh-hans is there. You need to translate your self, and replace translate js file.

How it works: It is using object defined in a js file, and look up for the value of input string.

To generate a template for the translation, I write a script (sorry for using powershell as I'm in a Windows system, it should easily done with a bash script.) It search every i18n() function call and generate a js template file with every entry not translated.

@benfre
Copy link
Author

benfre commented Nov 28, 2022

Related to issue #27 @Drachenkaetzchen

@benfre benfre changed the title Benfre master i18n implement Nov 28, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant