Comments (20)
i wish i put out roots with i18n support included.. i was thinking we need to follow the guidelines stated here:
http://codex.wordpress.org/I18n_for_WordPress_Developers
how does WPML compare to that?
from sage.
WPML follows exactly those guidelines but add facilities to run the site multilingual:
- adds a language switcher
- enables content translation (posts/pages,custom post types, categories , ....)
- adds a facility to translate gettext strings in the database instead of po file from the wp backend
- adds a facility to import / export po file in the db from the wp backend
and more ;-)
from sage.
i looked through canvas and the only instance of 'wpml' mentioned is the wpml-config.xml
file in the theme root (which doesn't look like it does much)
would love to get all text fed through _e
though
from sage.
Yea basically everything we need to do is enable _e syntax on every hardcoded strings of roots, create a wpml-config.xml file (not mandatory though) and make sure that language switcher and alike feature behaves normally. It's not really a lot of work.
I can take care of this and take care of issue #6 also.
from sage.
Nice to see that you guys are working on it. I just found about this theme and the first question I was asking myself is "please be compatible with WPML"
from sage.
last week we got into the WPML's 'go global' program and will be starting and closing this issue soon
ps. looks like as of recently WPML has gone commercial
from sage.
Sweet !
Ben do you have more detail about this ? Or could you point me to a link ?
I should be able to spend some time on the theme this week so i'll give this a look.
Take care ^^
from sage.
On its way ...
from sage.
You can check my new wpml-integration branch on my fork.
I have taken care of every strings but left the include folder untouched.
Indeed , I'm waiting for a decision about #5 because if you accept my pull request I'd rather work on the options framework modified files than the actual ones to avoid further conflicts.
from sage.
While working on this i realized we need to be carreful to keep the theme working when wpml is not enabled. Dunno if wpml's team has something 'built-in' for this or if we need to use a simple if (exist(function()) test.
from sage.
so far everything works without wpml plugin, i haven't looked any deeper into integration though. the only other files we need to go over are in the includes/ directory [but we should finish up the options stuff first (see my twitter msg) before doing that]
from sage.
Yea offcourse the gettext use doesnt break anything. I was more thinking of custom areas like the language switcher and so on.
But for now let's stick to the gettext integration.
from sage.
new options are done, i haven't tested with wpml activated yet but let me know where we are whenever you've got a chance :)
from sage.
see bc2da28
added a .pot file generated by http://www.icanlocalize.com/tools/php_scanner
i think this ticket might be closed at this point. i'm not sure if we should add a language switcher since WPML includes a widget by default
from sage.
- you'll need both WPML + WPML String Translation plugins enabled
- after activating WPML and going through the initial setup, go to WPML > Theme and plugins localization and select Translate by WPML
- scroll down to Strings in the theme and click Scan the theme for strings and click View strings that need translation
i'm not sure if that roots.pot file is even necessary.. @johnraz let me know if you have any insight :)
from sage.
Well the pot file is useful to provide the localization. I'll translate the plugin strings to french ;-)
I don't know about the compatibility though. I think it still needs some in depth testing.
from sage.
my concern is with keeping the file(s) updated - if WPML already can generate the initial file on the fly is it worth it to include it anyway? i didn't consider including languages already translated, but that does make sense :p i just picture it being a pain to maintain
from sage.
Well Wpml can handle the translation by itself without the help of the po file.
The only point of the po file is to provide different translations.
Its your call whether or not we should provide translation.
I think we can rely on people with less technical knowledge to contribute to language files and that should keep them up to date... Let's dream @ people helping each other :-p
from sage.
I didn't have the time to push something about this but for the record: if an option is not declared by default using add_option() function - aka only registering it. Wpml will not recognize it and make it available for translation. So every custom entry in the option page that you want to be translatable must be declared with add_option.
from sage.
got an email from someone at WPML letting us know that they've tested it and everything is good, they also added roots to http://wpml.org/documentation/theme-compatibility/
from sage.
Related Issues (20)
- Bug: tailwind plugins import issue HOT 3
- Method ReflectionParameter::getClass() is deprecated Bug: HOT 1
- Bug: > cache/acorn/framework/cache directory must be present and writable HOT 1
- ❤️ Feature Request: static analysis of blade templates HOT 1
- Sage is incompatible with symbolic links : Unrecognized file extension HOT 1
- Replace single line PHP statements HOT 1
- Sage 9 + Wordpress 6.3 : Notice: Error when decoding a JSON file at path... HOT 3
- Can Sage 10 integrate React and use shadcn/ui? HOT 1
- Hot reload not working (Redirecting to base URL when front page is set) HOT 1
- @import tailwind syntax is not supported and can cause issues with bud cache
- Unable to use @import on css files HOT 1
- Use modern Yarn install
- [sage 9] page-template not working on wordpress 6.4 HOT 1
- Sage 10 tailwind css is not working without small addition to tailwind.config.js HOT 5
- Sage 9 + Wordpress 6.4 and 6.4.1 create broken Gutenberg layout HOT 3
- Admin bar breaking error pages HOT 1
- Seems eslint --fix doesn't apply prettier changes HOT 1
- do_action('get_header') should occur before wp_head() HOT 13
- "editor.css" not included when Gutenberg (block) editor is in the new iframe mode
- Tailwind logical properties classes does not work as expected HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from sage.