Plugin / Gengo

Jamie Talbot

Description

Description

Gengo is a full featured plugin that provides multi-language blogging for WordPress 2.5+. It allows for an unlimited number of translations and summaries for any post and provides template tags to display language information. It allows you to edit translations side by side, detects and filters by language automatically when a visitor comes to your site and automatically generates semantic information for links and content blocks. It is configurable via an options page.

Gengo is mainly written by Jamie Talbot, with some help from Paolo Tresso (aka Pixline) and the community.

More info & Support

Known Issues

What happens if Javascript / XHTMLHTTP isn’t available?

It won’t work, sorry. A large portion of the admin code relies on these technologies to update information in the background. There’s no way around this.

It doesn’t change the page items like “Categories”, “Links” etc

You need a specially internationalised theme for this to work. In essence, the theme has to use _e() and __() functions around its text and provide a localisation .mo file. Contact your theme vendor 😀

Previous and next links go to posts in other languages!

I know. WordPress won’t let me get at those just yet. It’s too much of a hassle to rewrite all that code, so you’ll just have to live with it for the time being, I’m afraid. I’ve submitted a patch to the core which would allow this to happen, so hopefully it will make it into WordPress 2.1… It’s at https://trac.wordpress.org/ticket/2415/ , where you can find out the status of the ticket and leave a comment to support its integration if you think it will be useful. You can also apply the patch yourself if you know what you’re doing. As soon as it is patched, Gengo will take advantage, with no further modifications.

I entered synonyms for my categories but they only show up in certain places. In others, the default is always displayed.

This is because WordPress applies the filter that Gengo uses inconsistently. I’ve added a ticket and patch to the core which hopefully will make it into WordPess 2.1. You can check the status of this ticket and leave a comment to add your support if you think it’s important at https://trac.wordpress.org/ticket/2466/ In the meantime, if you know what you’re doing, you can patch your files yourself using the patch there. In 2.0.4 this should be a little better than before.

The translation page doesn’t do anything

0.5 onwards provides some translation group management away from the write post screen. If you need more, let me know.

I get insert errors with MySQL 5.x

This happened in strict mode, and should be fixed in 0.8

The language tag is set incorrectly for feeds.

This should have been fixed from 0.81 onwards. However, for feeds for two or more languages, only the reader’s first specified language is used, as there is no facility for specifying multiple languages for RSS. This will be updated if and when WordPress supports a feed that understands multiple languages.

My Save buttons disappear forever when changing the language of a post.

This seems to be a browser related problem, especially some versions of Firefox. Make sure the Firebug extension is not snooping XMLHTTP requests as this is known to cause problems. Upgrading to the latest version of your browser should fix the problem. Gengo is known to have problems on some installations of Firefox 1.5 but works seems to work successfully with Firefox 1.5.0.2.

There are multiple UNIQUE indices on the wp_languages table.

This seems to be because of a bug in WordPress’ supplied upgrade function dbdelta(). This should be fixed now.

I have another request / bug / optimisation

Please let me know in the forums at http://jamietalbot.com/wp-hacks/forum/ . I’ll see what I can do to fix it.

Does Gengo work with WordPress x.x.x?

Gengo 2.5 only works with WordPress 2.5+. Version 0.9 works with WordPress 2.1/2.2, and 0.81 works with 2.0.1, but not 2.1.

I don’t have an option to view in multiple languages

Reading in multiple languages is only supported for MySQL versions 4.1 and above. If your MySQL is lower than that, the option won’t appear. You really should start bugging your host for a better MySQL version – WordPress 2.2 is only going to support MySQL 4.1+.

Template Tags

Gengo provides a number of template functions which are very similar to those in WordPress:

  • gengo_list_languages() – outputs a formatted lists of languages defined for this blog. Surround the call to this function with <ul> tags.
  • gengo_link_pages() – replacement for wp_link_pages().
  • gengo_next_posts_link() – replacement for next_posts_link().
  • gengo_previous_posts_link() – replacement for previous_posts_link().
  • gengo_snippet() – allows you to insert small, translated blocks of text.
  • gengo_trackback_url() – replaces trackback_url().
  • gengo_viewing_languages() – outputs a list of languages that the user is currently viewing, with js links to change priority.
  • gengo_available_languages() – outputs a list of languages that the user isn’t reading in, but are also available.
  • gengo_language_set() – outputs save and reset to store reading options.
  • gengo_language_control() – combines the previous 3 functions.
  • gengo_home_url() – the home url appended with the current viewing language.
  • is_language() – tests we are currently viewing a language.
  • the_language() – outputs or returns the language for a page where only one language is being used. Outputs by default. To return the language as a string, call the_language(true).
  • the_language_code() – outputs or returns the current language code. Outputs by default. To return the code as a string, call the_language_code(true).
  • the_language_locale() – outputs or returns the locale for a post.
  • the_language_direction() – outputs rtl or ltr.
  • the_viewable_languages() – outputs or returns the languages the user is reading in.
  • the_viewable_codes() – outputs or returns the languages the user is reading in.
  • the_summaries() – outputs a div with a javascript switcher of all of the summaries for this post, or nothing.
  • the_translations() – outputs a list of translations for this post, or “No Translations”.
  • the_translations_comments() – outputs a list of links to the comments sections of translations for this post. Use in comments.php.

DIRECTORY DISCLAIMER

The information provided in this THEME/PLUGIN DIRECTORY is made available for information purposes only, and intended to serve as a resource to enable visitors to select a relevant theme or plugin. wpSocket gives no warranty of any kind, express or implied with regard to the information, including without limitation any warranty that the particular theme or plugin that you select is qualified on your situation.

The information in the individual theme or plugin displayed in the Directory is provided by the owners and contributors themselves. wpSocket gives no warranty as to the accuracy of the information and will not be liable to you for any loss or damage suffered by you as a consequence of your reliance on the information.

Links to respective sites are offered to assist in accessing additional information. The links may be outdated or broken. Connect to outside sites at your own risk. The Theme/Plugin Directory does not endorse the content or accuracy of any listing or external website.

While information is made available, no guarantee is given that the details provided are correct, complete or up-to-date.

wpSocket is not related to the theme or plugin, and also not responsible and expressly disclaims all liability for, damages of any kind, arising out of the use, reference to, or reliance on, any information or business listed throughout our site.

Keep Leading Your Followers!
Share it for them.