Posted: June 26, 2012 at 11:56 pm
|
Hi there, Thank you for your time. -Stéphane |
I do. We are actually looking into adding support for the qTranslate plugin. So something like this: Here’s more info about getting a plugin to add support for qTranslate: |
|
|
Thanks Josh! We use __() and _e() extensively for string translations. Now regarding your example, I believe __() will not have the desired effect. qTranslate works like WPML, and from what I gather from the link only static text can be translated with __() [or static text with placeholders] not dynamic text. And by Dynamic text what I mean is user generated, stored in a database and not some that is hard coded in a file. So lets say we were to add filters and then use either qtrans_useCurrentLanguageIfNotFoundUseDefaultLanguage or icl_t() in the case of WPML this would only make the strings such as event description and etc appear in the wpml string translation backend like such: http://www.liberal.ca/files/2012/06/wpml.png which is far too cumbersome for most of our users (we want to allow users in various offices to submit events for approval with the permissions plugin) Therefore an interface more like this: https://www.liberal.ca/files/2012/06/language.png where the events are linked in some fashion and they are entered by the end user twice or some info is entered twice would be preferable. What are your thoughts on this? Thanks again, -Stéphane |
Sounds like you know more about this than I do. If we were going to add ML support to Event Espresso, we would have to make it possible to change dynamic strings, so the example I gave above wasn’t the greatest. You raise an interesting thought about the user submitted end of things. We’re actually working on a front-end event submission tool that will work along with the permissions add-on. Adding ML support to Event Espresso isn’t something we’re able to tackle right now, but we are certainly looking into ways to make it work with ML plugins/solutions. |
|
@ Stéphane __() can be used for dynamic text/variables. We use it all over the place in the code. That solution was actually sent to us from a user who is using qTranslate and they got it from the qTranslate devs. What you may be thinking is _e() which canNOT be used with variables but rather needs to be a string.
|
|
|
Hi Chris, Thank you for that. The good news is that I’m not looking for you guys to build the multilingual events aspect. We’re more than happy to do that ourselves, we’re just looking for guidance in terms of what you guys would think is the best way to logically structure multilingual events. Is it to just dump all the strings in a translation plugin? That’s a bit harder to use for the end user than if we were to create 2 events and link them or something of the sort. Your thoughts on the matter are greatly appreciated |
|
Turns out WPML has a feature called Auto-Register strings that takes the content from __ and _e and registers it as strings to be translated, its just off by default and a bit hidden! |
I don’t know what the best solution would be for WPML. We haven’t tested or developed with WPML in mind. |
|
…that said, if WPML supports __(), it should work in the same way (assuming you’re doing that in the actual template files and it’s not something that gets done in the post or something like that). Again, we haven’t had a chance to test this all that much, but I do know that someone was able to get qTranslate working this way (or at least, we didn’t hear that it wasn’t working after we pointed them in this direction in response to qTranslate’s support response for how plugin developers could/should handle their strings to allow them to be supported by their plugin. But, we can’t guarantee it will work flawlessly because, again, haven’t had the opportunity to do much testing or implementation. However, this is the route we are/I am planning on pursuing to try to make EE multilanguage-compatible.
Yes, but that would be a whole lot easier to implement than trying to link to separate events (which would involve some SQL magic to get the event information to sync up, and some more SQL and PHP and possibly some JS magic to filter the version that is not in the language you want to display from appearing in the event list and on the calendar). Getting some kind of multilanguage plugin to read your event description variable and spit out the correct translated string is much simpler.
|
|
The support post ‘Translating Events ( WPML intergration?)’ is closed to new replies.
Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.