skriker

Polyglot

autor - malyfred / 22. 2. 2005 /
  • english

Example

Dva studenti hledají brigádu na léto, nejlépe přepisování textů na počítači. Zn. Jsme spolehlivý a pracovitý. (Nalepovaný inzerát na Kladně. Osobně bych radši najal toho pracovitého.)

This post is here to introduce the plugin called "Polyglot" – plugin for complete and easy localization of your blog into several languages. Polyglot is based on Language Picker. If you have any problem reading documentation of Language Picker can be helpful. I have developed it for my private use but some other guys/gals could be interested (hello Mihailo:o) as well.

I have fixed all bugs in Language Picker that I've found and added ability to automatically detect the visitor's preferred language and then choose the right translation for him/her. You can try it here – with this post. Example above should be in czech or english according to your selection or preferred language in your browser.

How it works

For example this post actually looks like this:


[lang_cs]Dva studenti…[/lang_cs]

[lang_en]In a Rhodes tailor shop…[/lang_en]

This post is here to…

And that's it. You can translate titles of the posts, pages, names of the categories etc. in the same way.

ISO codes

You are supposed to use [lang_xx] where 'xx' is the ISO code of the language. These can be found here: ISO codes

Language versions

If you put to your index.php (and single.php, search.php etc.) in your themes something like this:

<?php if(function_exists('polyglot_other_langs')) {
//display existing language versions of the post
polyglot_other_langs(' ','<ul>', '</ul>', '<li>', '</li>');
}?>

(must be inside of the WordPress loop) you allow your visitors to choose the language version of particular post (as could be seen above).

Flags

Name of the language or associated flag will be shown according to the value of $polyglot_settings['use_flags']. (Thx Mateusz Łoskot for inspiration)

Preferred language

Then you can offer your visitors to set preferred language for entire blog (as you see in my menu). It can be done by code like this:


if(function_exists('polyglot_list_langs')){
polyglot_list_langs(false);
}

that you put e.g. in your sidebar.php. Function polyglot_list_langs() accepts one optional parameter true or false that says whether names of languages or flags should be shown.

RSS

You can also offer RSS feeds in different languages:

<a href="<?php bloginfo('url'); ?>?feed=rss2&lang_view=en"> English RSS</a>

Last thing you have to do is to specify languages of your blog in polyglot.php. Basically – you just add ISO codes to the array $polyglot_settings['knownlangs'].

If there is no suitable language version of text present – then the default language version is selected. If even default language version is not there – then only parts that are not translated are shown.

Template localization

Because Polyglot changes dynamically prefered language of your blog – you don't have to do anything special to translate your blog except that everything in your templates that should be translated must be "gettexed". And appropriate .mo files must be in your wp-includes/languages directory. You can get them here: WP localization files and they should be renamed to xx.mo where 'xx' is the ISO code of certain language.

Time & Date

Time and date formats can be cusomized to fit the language traditions since the versin 0.8.

Permalinks

Permalinks are fully supported, and turned on by default, since version 2.0 was released

Comments

The version 0.8 has also introduced the ability to write comments on posts in more language versions. Your visitors must use [lang_xx] instead of <lang_xx>.

Other useful plugins

You can also try some other of my plugins: IImage Browser, IImage Gallery, IImage Panorama, JÄÅ Preview.

Known issues

  • You have to set WPLANG (e.g. define('WPLANG', 'en');) in your wp-config.php. Thank you Pete!
  • If you are using WP older than 1.5 – uncomment part of the code from line 125 and comment part from line 139.

Important

Since version 0.8 you can use [lang_xx] instead of <lang_xx>. That's useful for those using WYSIWYG editors.

Fixes

01.04.2008 – WP 2.5 compatibility improved
27.01.2008 – WP 2.3 compatibility improved (tags, links, initialization,…)
11.10.2007 – few RSS related filters added
27.05.2007 – some setcookie improvements
22.05.2007 – small improvements related to new features in WP2.2
29.01.2007 – version 2.0 released. Many new features and improvements added (permalinks among others).
24.03.2006 – original WP function trailingslashit doesn't work as intended so it has been replaced by polyglot_trailingslashit
20.01.2006 extended polyglot_the_date, now accepts $before & $after
extended polyglot_list_langs, now sets a class for the <li>s (language_item and current_language_item)
Thanks Jan for all these improvements!
07.01.2006 Tag [lang_xx] added
18.10.2005 Huge update – flags added, 'translate categories' plugin implemented etc.
25.5.2005 Polyglot is now using standard load_default_textdomain() function.
13.3.2005 Tag <lang_all> is since this moment optional – everything except translated parts is handled as <lang_all>
12.3.2005 Fixed problem with WP1.5 – thanks Matthias.

Download

polyglot2.5.zip.

default_gettext.zip – fully gettexed default theme. (thanks to Maira)

Let me know

I'd appreciate if you let me know that you use Polyglot on your web. You can also choose whether you want to be informed about new versions:

How to translate categories

There are two ways. At first you can write translations directly to the category 'name' using [lang_??] tags. But WordPress is limiting the name length to just 55 characters so you will have a problem to fit all translations inside. I'd recommend you increasing the length of 'name' column in 'items' table (WP <2.3 – 'cat_name' column in 'categories' table) in your WP database. Second way is to add all translations of categories to your .mo files and Polyglot will try to translate them. It's tested with wp_list_cats() function.

  1. Mihailo 22. 2. 2005 / 3.10

    Yay!!! I also wish this something like this becomes part of the core. I’d also like to see it more advanced, so that instead of using lang tags, each article article and/or category would have separate language field, and selected for displaying based on that.

    Till then, I’m off to play with Polyglot :) Thanks!

  2. Jason 22. 2. 2005 / 23.36

    I’ll have to take a look when I get some time… I’m glad somebody’s working on stuff like this; I wish I had the time to continue with it myself…

  3. Yves 27. 2. 2005 / 23.23

    Nice work! Works like a charm. One problem though with the “previous post” and “next post” links that displays the titles of the preceding and following post in the single.php view. It show the titles for all languages , one next to the other. Any workaround? What about a mini “the loop” just for this navigation part?

  4. malyfred 28. 2. 2005 / 1.33

    >Yves It should be possible just to add proper hook for this in polyglot.php. If you could not find the right one I would suggest to call the lang_picker_respect_more("your text") function on this. Where you replace “your text” with whatever should be “polygloted”.

  5. Yves 2. 3. 2005 / 0.50

    Well, after much head scratching and Plugin API documentation reading I saw the light (I am a newbie PHP meddler) and added
    add_filter('next_post', 'lang_picker_respect_more',1);
    add_filter('previous_post', lang_picker_respect_more',1);
    to polyglot.php but with no effect.
    These functions however are not referred to as available filter hooks in the Codex but I don’t quite know what I am missing.

    Oh and on another note, Would you know where to find a gettexed version of the Kubrick theme?

  6. malyfred 2. 3. 2005 / 3.12

    >Yves These hooks seem to be good for it and if it doesn’t work – we have to “dig deeper” in the code…:o( Gettexed Kubrick should be soon on official WP web. As far as I know – they are working on it. Look into archive of wp-polyglots mail list: wp-polyglots.

  7. Yves 2. 3. 2005 / 20.33

    Thank you for your reply. I may settle for more conventionnal “next post/previous post” links in the meantime.
    I did find a hint that fully gettexed themes might not be feasible until version 1.5.1 .I decided for the short term to use the theme-switcher plugin to switch between two hard translated theme, now the challenge is to have the same link switch the theme and the language of the post and the locale! An hybrid between polyglot and theme-switcher?

  8. malyfred 2. 3. 2005 / 22.29

    >Yves Actually it shouldn’t be so hard. Just let the Polyglot do its work and change the themeswitcher to respect selected language. It could be like 4 lines of code!

  9. neingeist 14. 3. 2005 / 21.12

    TrackBack: neingeist » The Tower of Babylon

  10. freshlabs - Wordpress multilanguage 15. 3. 2005 / 12.13

    […] rschiedene Ansprüche. Bislang habe ich zwei davon ausprobiert: Polyglot (Autor URI: http://fredfred.net/skriker/index.php/polyglot) Polyglot erlaubt es, die Sprache in einem Post mi […]

  11. joe 20. 3. 2005 / 17.25

    How did you manage to change the menu titles also? I attempted to specify the variations in the code in the same way as you would for making a multi-language post, but no luck… is it something to do with the mo files? they didnt seem very editor friendly! I hope you don’t mind me asking… :>

  12. malyfred 20. 3. 2005 / 17.36

    >joe At first you have to “gettexed” your templates – so for example in sidebar.php you need something like this:
    _e('Categories') instead of just ‘Categories’.
    Then you have to download .po file of your tranlation and add the tranlations of all string that are not in the default WP version. Then use poEdit to generate your own .mo file. And that’s it. If you want to translate categories as well – let me know – I can release plugin that I am using for that purpose.

  13. IImage Browser | skriker 21. 3. 2005 / 5.38

    […] one for you if you like 360° panoramas. If you would like to have multilingual blog – try Polyglot. Download: iimage-browser.1.4.2.zip iimage-browser.1.4.3.zip – beta – IImage Browser butt […]

  14. IImage Gallery | skriker 22. 3. 2005 / 13.18

    […] rowser for adding images to you galleries and IImage Panorama if you like 360° panoramas! Polyglot is for those who would like to have their blog or posts in more languages. Download: iima […]

  15. Sean 23. 3. 2005 / 14.37

    Hi Malyfred,

    I just love your plugins. Use your image plugins on http://www.seansite.net and will try out your language plugin on http://www.bandung.seansite.net.

    But got some issues when it comes to your language plugin which I hope you can help me with (tried the address to Language Picker as mentioned in your post, but I can’t get it to work):

    1. How did you get the language link on the same line as the post date and so on? Whatever I do I get it on the line below. You can see it on http://www.bandung.seansite.net. Doesn’t look to nice :-/

    2. I added both english and indonesian to all posts (4) on http://www.bandung.seansite.net. But only the two first ones comes in indonesian if I choose that language from the sidebar. Why?

    3. Downloaded a version of indonesian, wanted to upload it to wp-includes/languages. The folder languages wasn’t there so I made it myself. Hmmmz, can’t see that It make use of my id.po file. Any idea why?

    Thanks again for your great plugins. You are abviously a gifted guy when it comes to making plugins :-). Hope that you can help me out on the issues above.

  16. malyfred 23. 3. 2005 / 19.53

    >Sean Thank you:o)

    1) That’s a question of CSS: display: inline;

    2) I think that in your case it’s because of <!–more–> tag. Your post should look like:
    <lang_en>english bla bla</lang_en>
    <lang_xx>xx bla bla</lang_xx>
    <!--more-->
    <lang_en>english vla vla</lang_en>
    <lang_xx>xxx vla vla</lang_xx>

    3) .po is just source for .mo file and that one must be in wp-includes/languages directory. Use poEdit to generate it

  17. Sean 24. 3. 2005 / 4.33

    Malyfred,

    Thanks for your quick reply on my newbie questions :-)

    1. WHere should I add display: inline; in my style.css? Tried to add it to post-content but didn’t work, then tried to make post-content ul li and added it there but still didn’t work.

    Also tried to find others who had added this plugin to see what they have done, but can’t find any.

    Fantastic if you can help me out, if not I’ll just have to look around for a bit longer.

    2. You was right. Thank you :-)

    3. Added the .mo file now … but nothing happens.

    All this is for http://www.bandung.seansite.net.

    Thanks again!

  18. malyfred 24. 3. 2005 / 21.48

    >Sean
    1) you have it in: post-title so…

    3) have you added ‘id’ to the list of allowed languages?

  19. joe 25. 3. 2005 / 20.31

    It would be great to see your plugin to do that yeah… I think I will want to translate the categories too yes. Thank you very much for sharing the info with me on how to change the titles!

  20. malyfred 31. 3. 2005 / 20.18

    >joe I have added translate-categories.zip plugin to the download section. Try it.

  21. Moshu 5. 4. 2005 / 16.52

    Hi malyfred,
    I tried to use this plugin, but only with half success. I mean I got it work in the post title and inside the post, using the code provided, even the link for switching languages shows up in the meta line…
    But I have problems when wanting to change the language for the whole site. As I can see on your site clicking the “cesky” in the meta lione of the post will change the language in the sidebar. That didn’t work for me.
    Also, using the code for the sidebar menu for language change gives me an error.
    Am I missing something?
    (p.s. It is not on the blog I linked in my name here, it’s on a testbed.)

  22. malyfred 5. 4. 2005 / 17.15

    >Moshu Comment #12 doesn’t help?

  23. Moshu 7. 4. 2005 / 18.24

    Thanks, Malyfred, but not really. I am beyond that see this.
    Anyway I’ll give it a try again, will see what happen!

  24. ken1 10. 4. 2005 / 19.46

    hello
    ne at this and trying to install polyglot plugin on my blogsite…
    question:
    in what file should i put the htmlcode you are talking about
    /?lp_lang_pref=en”>English

    regards

  25. ken1 10. 4. 2005 / 19.48

    äsch…grrr..
    you know what code i mean right?


    Then you can offer them to set preffered language for entire blog as well (as you see in my menu). It can be done by code like this:

    /?lp_lang_pref=en”>English

    You are supposed to use where ‘xx’ is the ISO code of language. These can be found here: ISO codes

  26. diego_moreda 10. 4. 2005 / 23.05

    hello,

    i am having some problems with the plugins, same one as most people have. i can display the posts in several languages, but i cant display the other parts of the weblog in a localized version. furthermore, if i activate the plugin the blog localization is overriden (ie. i have set the WLANG to spanish, and the blog, web admin, etc is in spanish if the plugin is not activated; it switches back to english if activated).
    i have tried several things but nothing worked … any help would be much appreciated.

    keep the good work!

  27. malyfred 11. 4. 2005 / 0.24

    >ken1 Yes I know:o) You can put it anywhere you want. I have it in sidebar.php but it depends on you. It’s just a link that change the language when you click on it.

  28. malyfred 11. 4. 2005 / 0.27

    >diego_moreda have you set $default_lang and $knownlangs properly? Because otherwise you don’t have to do anything special to switch the language of other stuff on your page. What the Polyglot does is actually nothing more than changing the value of WLANG according to user’s preferences. You just have to use gettext in you template and put translated strings into your .po/.mo files.

  29. Christoffer Soop » Blog Archive » A Polyglot WordPress? 15. 4. 2005 / 12.28

    […] should thus be considered as a cross-cutting concern. Update: I just found out about the Polyglot plugin which seems to do the trick. Haven’t tried it yet, but it seems promising. […]

  30. wyrfel 15. 4. 2005 / 19.05

    Hei guys, i just found a probable solution to the problem of a non working site localization: looking at the code you’ll realize that polyglot dupes part of code that is already present in wp-i10n.php .
    Look for if ($lang_change_locale && class_exists(‘streamreader’)){ and comment out everything from if ( is_readable($mofile) && ($locale != ‘en_US’) ) { tp gettext_reader($input);//fred for WP1.5 or later
    }. Then add
    load_default_textdomain(); right after that.
    That should do it.

  31. wyrfel 15. 4. 2005 / 19.08

    Ok, more readable again:
    Before:

    if ($lang_change_locale && class_exists('streamreader')){
    $locale = $lp_lang_pref;
    $mofile = ABSPATH . WPINC . "/languages/$locale.mo";

    if ( is_readable($mofile) && ($locale != 'en_US') ) {
    $input = new FileReader($mofile);
    } else {
    $input = false;
    }

    if(get_settings('version')

    After:

    if ($lang_change_locale && class_exists('streamreader')){
    $locale = $lp_lang_pref;
    $mofile = ABSPATH . WPINC . "/languages/$locale.mo";

    load_default_textdomain();

    require(ABSPATH . WPINC . '/locale.php');
    }

  32. wyrfel 15. 4. 2005 / 19.09

    I’m giving up, you know what i mean. ;-)

  33. wyrfel 15. 4. 2005 / 21.03

    Also found a solution for the problem with the previous_post/next_post links… You will have to edit wp-includes/template-functions-links.php. It includes the previous_post() and next_post() functions. Within those replace $string .= wptexturize($nextpost->post_title); with $string .= wptexturize(apply_filters('the_title', $nextpost->post_title, $nextpost));. Make sure to replace $nextpost with $lastpost for the previous_post function.

  34. every little secret » Blog Archive » New plugin found 16. 4. 2005 / 21.27

    […] 尚宮です!

    四月 17th, 2005
    New plugin found

    Polyglot 正是我想用的plugin,但似乎不是為初階用戶以設,嗯,改天要試試 […]

  35. r0n 18. 4. 2005 / 18.29

    Hello, thank you for cooking out this great plugin! Works like a charme for my posts. However one thing with WP 1.5 puzzles me a bit: When writing “PAGES” in different languages, I´m using english and german, there´s always the german PAGE content displayed on my site. It doesn´t pick the ‘lp_lang_pref=en’ variable with PAGES. As mentioned above, POSTS are fine.. When adding ‘?lp_lang_view=en’ to PAGE link URI it´s being displayed in english. Is it because the polyglot plugin doesn´t work with WP 1.5 PAGES or am I just overlooking anything? Thanks for attention so far

  36. malyfred 20. 4. 2005 / 10.32

    >wyrfel thx. it seems that you are using night build of WP right?

  37. malyfred 20. 4. 2005 / 10.38

    >r0n It should work with pages without any problems. You just have to edit template for pages to show the links for language versions on proper place. Another hint: Have you tried ?lp_lang_pref=en?

  38. r0n 20. 4. 2005 / 11.23

    I got it: I just C&P your suggested code for global blog language preferences :
    <a>/?lp_lang_pref=en">English</a>
    : however after I removed that slash before ?lp_lang_pref=en :
    <a>?lp_lang_pref=en">English</a>
    : PAGES will be displayed in the proper language now. Thanks for your feedback, I really appreciate. Whooh, now I´m really fine with my Blog and will go online soon ;))

  39. Loïc 21. 4. 2005 / 4.49

    Comment #30 worked for me too. Titles in sidebar are translated now.

    $mofile = ABSPATH . WPINC . "/languages/$locale.mo";
    /*if ( is_readable($mofile) && ($locale != 'en_US') ) {
    $input = new FileReader($mofile);
    } else {
    $input = false;
    }

    if(get_settings('version')

  40. Loïc 21. 4. 2005 / 4.50

    end of preceding post …

    $l10n[‘default’] = new gettext_reader($input);//fred for WP1.5 or later
    }*/
    load_default_textdomain();

  41. Francis 21. 4. 2005 / 17.24

    Thank for this plugin! Very usefull. It seems to work. However, when switching from English to French, I have this message at the top a my screen before site content :

    Warning: Cannot use a scalar value as an array in d:\serveur local\easyphp1-7\www\wordpress\wp-includes\wp-l10n.php on line 74
    At the same time, all text become taller.

    Do you have a solution for me ?

  42. malyfred 21. 4. 2005 / 20.23

    >Francis Look at Known bugs and change the code as you need.

  43. Francis 25. 4. 2005 / 16.32

    Well Malyfred, thank you for your reply. But as a beginner,
    even passionate, and don’t understand what I should do with those
    lines of code (around line 75). I get lost. I’m using WordPress 1.5.
    Having my site fully bilingual under WordPress is crucial to me and it seems that your plugin is a must. Thank you again for your help.

  44. malyfred 25. 4. 2005 / 20.09

    >Francis I’ve mentioned that this plugin is not for pure beginners! But anyway – the code looks like this:
    if(get_settings('version')<'1.5'){
    $l10n = new gettext_reader($input);// before WP1.5
    }
    else{
    $l10n['default'] = new gettext_reader($input);// for WP1.5 or later
    }

    But sometimes the version number detection doesn’t work. In your case you should replace all this code by :
    $l10n['default'] = new gettext_reader($input);

  45. Daniel S. Haischt 26. 4. 2005 / 20.06

    If noone figured out already – This is the way how to localize the previous/next link in WP 1.5.

    You need to use the previous_post_link()/next_post_link() functions in your templates instead of previous_post()/next_post().

    If you take a look at the source of template-functions-links.php, you will figure that the standard previous_post() function is not using the apply_filters() function. previous_post_link() does!

    Cheers!

  46. Blog Archive | HILFE!!! 28. 4. 2005 / 17.05

    […] aquo; Mono-what? HILFE!!! Weiß jemand, wie ich das nette plugin polyglot installiert bekomme? Bitte helft mir!!! Dieser […]

  47. Yves 30. 4. 2005 / 16.52

    > Daniel S. Haischt comments #45
    Thank you for the Tip! It works perfectly!
    > Loic #39 and wyrfel #30
    Big thanks to you guys too.

    I struggled a bit to to manage to translate categories so here are the details:

    1) Install the plugin and activate it
    2) You have to edit the PO file for your target language (see The Codex for details). In this Po file insert your category names and their translation. Save it as a *.mo file and override the one you already have.
    3) Thats’ all. Enjoy!

    There is still the trouble of wp_list_pages() not displaying the translated page names or the fact that all the languages appears in the Archives/search pages but that might be easier to solve in version 1.5.1

    An again, thank you Jason and Malyfred for the tremendous work.

  48. Blomstereng.org - Blog » Blog Archive » LanguageSprk 30. 4. 2005 / 18.15

    […] « Plastic Toys Sprk N har jeg ftt installert ett nytt multi sprk plugin her p blogen. S n blir det litt mer oversiktlig her. Som fr kan man ve […]

  49. Rob 13. 5. 2005 / 19.03

    There was an XML validation problem with your plugin which was easily fixed. It involves changing the function lp_other_langs to output “&amp;” instead of “&”. Check out this url for more info:
    http://www.htmlhelp.com/tools/validator/problems.html#amp

    A very good plugin otherwise. Thanks for the hard work.

  50. empdesign | Blog Archive | Plugins Wp 16. 5. 2005 / 18.54

    […] lugin For WordPress: Permite añadir un sistema integrado de encuestas en la bitácora. Polyglot: Versión mejo […]

  51. Carlo 19. 5. 2005 / 3.23

    Your plugin works like a charm! The only problem I’m having now, is that I can’t manage to set italian as the language displayed by default (I did set ‘it’ as preferred language in Polyglot.php). I’m also forced to put even italian parts between lang tags, otherwise both versions are displayed.
    Can you suggest me a solution?

    Thanks in advance, Carlo.

  52. malyfred 19. 5. 2005 / 4.05

    >Carlo That’s not a bug that’s a feature:o) There has been left old and not-true-anymore comment for default lang.

    Current behaviour of filtering lang versions is described in the post. Every language version must be enclosed by <lang_xx> tags and unenclosed text is always shown.

    And about your ‘it’ issue – don’t forget that Polyglot gets the information about your prefered language from the browser and there is english set as default in most cases. Default language is not used if your post has appropriate language version.

  53. Carlo 19. 5. 2005 / 4.48

    malyfred, thank you for replying so quickly.
    As you can see in my blog, I managed to make it work, just by adding to my main template the code you suggested above for the global language prefs. :)
    Now everything is working as I want.
    Next step will be to make the whole blog bilingual…
    Thank you again, and keep up the great work!

    Best regards,
    Carlo.

  54. Pete 21. 5. 2005 / 16.16

    Hola, I don’t know if its mentioned anywhere, but at least for me I had to change in wp-config.php the line
    define (‘WPLANG’, ”);
    to
    define (‘WPLANG’, ‘en_US’);
    (or put your own localization in), to get ?lp_lang_pref=en (or some other language) type switching working. Otherwise language switching for whole blog didn’t work, I guess it got always overwritten or something as locale.php checks for empty string.

  55. Pete 21. 5. 2005 / 18.58

    … and I got this to work fabulously with WP-Cache by changing the cookie name in polyglot.php to wordpress_lang_pref (wp-cache searches for “wordpress”). Dunno if it is the proper way though.

  56. malyfred 21. 5. 2005 / 21.23

    >Pete Thank you! That could be answer to many questions here. It’s also good to know that polyglot works with WP-Cache.

  57. fethiye 22. 5. 2005 / 22.01

    thanks for this great plugin! have been using it for a while now, and now i want to add the translate-categories, but that does not seem to work. downloaded, activated it but still shows my category as a huge text including the etc tags…

  58. malyfred 22. 5. 2005 / 22.42

    >fethiye Of course – because translate-ctagories works in a different way. You have to add translations of names of your categories to your .mo file. You cannot use tags as in your posts.

  59. fethiye 23. 5. 2005 / 3.21

    thanks for the quick response. the .mo file for my language (Turkish) does not exist. So I made a very basic .po file (containing “Categories” and one of my categories’ name) compiled it and dropped it into the multilingual subdirectory. Nothing seem to change. Seems like I am missing something easy, but what?

  60. Training Today’s Athlete » WordPress Plugins 23. 5. 2005 / 4.58

    […] ic/tools/wordpress/wp-gatekeeper.html Polyglot for multilingual posts and stuff like that. fredfred.net/skriker/index.php/ […]

  61. malyfred 23. 5. 2005 / 10.36

    >fethiye I’ve tried to download tr.mo file from your server and it seems that it is not at the proper place: wp-includes/languages/tr.mo

    Try also simple _e("your testing category") code in your template, as translate-categories could be buggy.

  62. JÄÅ Preview | skriker 23. 5. 2005 / 17.05

    […] and activate it. P. S. You should also try these plugins: IImage Browser, IImage Gallery, Polyglot, IImage Panorama BTW do you know how to pronounce JÄÅ? No? Ok – just like this: yaeo:) […]

  63. fethiye 24. 5. 2005 / 23.03

    Thanks a lot for your help! I just didn’t know where to put the .mo file, and could not find any info about it. Now it is in the directory you specified, but nothing changed ;( I also put the .po file there — a basic one. Maybe I am doing something wrong with that one, too!

  64. malyfred 25. 5. 2005 / 1.32

    >fethiye simplest test: do you have _e('Categories'); in your sidebar.php? .po file seems to be ok. Which version of WP do you use?

  65. fethiye 25. 5. 2005 / 7.11

    I am using WP 1.5, and yes I do have _e(‘Categories’) in my sidebar.php (just double checked it). I also added that “bread” -> “ekmek” as a category in that .po file, too. Oh, yes, I do have this plugin activated as well.

    thanks again for looking into this!

  66. malyfred 25. 5. 2005 / 11.09

    >fethiye I’ve changed the code of Polyglot a bit – download it now and let me know.

  67. Sylvain 25. 5. 2005 / 15.23

    I’m glad to see I’m not the only one who has problems w/polyglot! ;-) I’m a newbie w/WP and malyfred was really helpful when I sent him an email about the installation (thanx again, dude!). Reading through this forum I finally was able to get not only the posts, but the rest of my blog translated too (Pete’s comment #54 did it for me! Thanx, man). One weird thing, though: not all of my page gets translated (words like “Categories”, “Archives”, “Links” etc.) remain in English, even if they ARE in my .mo files, but their subcategories come out properly!?!? What’s with that? One more thing, I’ve been searching the web like a madman and read everything I could on gettext for the past week, but I still can’t figure out how to “gettext” anything. I mean, there’s not even a .exe file in the bundle I’ve downloaded!!!Would anyone care to explain this ssssssllllllloooowwwwlllyyy, please.

  68. ☆MY BLOG☆僕のブログ☆MON BLOG☆ » Blog Archive » blogging from downtown Sendai on my cellphone… 25. 5. 2005 / 15.25

    […] rom downtown Sendai on my cellphone…

    Ain’t that awesome! (^O^)/♪

    This entry was posted

    on Tuesday, M […]

  69. malyfred 25. 5. 2005 / 20.02

    >Sylvain OK – how to gettext anything, let’s use the word “Categories” in your sidebar.php as an example.

    Open the sidebar.php in your favourite text editor (preferably supporting UTF-8, but…). Find the word “Categories”. It can look e.g. like:
    <h3>Categories</h3>
    chage it to this:
    <h3><?php _e('Categories');?></h3>

    and you have successfully gettexed “Categories”.

  70. I did it my way » Blog Archive » Multilanguage Mehrsprachigkeit 26. 5. 2005 / 9.06

    […] hen die kein Deutsch sprechen. Damit man nicht beide Texte lesen muss hilft mir ein nettes Worpress-Plugin.

    This entry was posted

    […]

  71. fethiye 27. 5. 2005 / 2.25

    the new polygot didn’t seem to change anything…

  72. malyfred 27. 5. 2005 / 22.48

    >fethiye hmmm – have you tried comment #54?

  73. Sylvain 29. 5. 2005 / 8.53

    >malyfred You’re the man! Thanx to you it looks like I’ll be up and running on schedule (June 1st)… One thing, though, I can’t seem to find some of the strings I’d like to “gettext”, like “Leave a comment” for example. I’ve looked in every file manually, ran a search through windows, etc. I know it must be somewhere, because you changed it to “Napsat komentář” and “Kommentera”. Sorry I’m so persistent, but I’d really like to give my readers the option to have everything in their prefered language.

  74. malyfred 29. 5. 2005 / 10.03

    >Sylvain C’mon! Try harder! comments.php and “Leave a Reply” in your current theme.

  75. The Blog of Henrik Pauli » WordPress Polyglot plugin 29. 5. 2005 / 18.35

    […] Uncategorized — Henrik Pauli @ 18:35 One of the plugins I’m using is Polyglot, which would be good if it did a couple things differently.  One of them being showi […]

  76. r0n 1. 6. 2005 / 14.24

    does anyone know if there´s a way to insert the currently displayed language into header meta tags?

    <META name="language" content="<?php need_function () ; ?>">

  77. malyfred 2. 6. 2005 / 20.52

    >r0n Download the latest version of Polyglot and set $polyglot_settings['print_meta'] = true;

  78. r0n 3. 6. 2005 / 10.25

    Thanks a lot, Fred!

  79. r0n 3. 6. 2005 / 12.38

    I´ve been running into a couple of more issues about getting the currently displayed language value (Fred may already know…) so I added two simple functions to my polyglot.php which ECHO or RETURN the ISO code:


    function polyglot_echolang(){
    global $lp_lang_pref;
    echo $lp_lang_pref;
    }

    function polyglot_returnlang(){
    global $lp_lang_pref;
    return $lp_lang_pref;
    }

    The functions seem to be working with either ?lp_lang_pref=XX or ?lp_lang_view=XX on my site.

    May be useful i.g. to offer localized RSS feeds like:

    <?php bloginfo('rss2_url'); ?>?lp_lang_view=<?php polyglot_echolang(); ?>

    or whenever one needs to offer different content for each language, like <META> description, keyword TAGs etc..

  80. De Culturis Mundi 3. 6. 2005 / 19.25

    Multilingual blogging

    First of all: some clarification is due about the terminology. As I mentioned in one of my first posts I chose WP beacuse I loved “the possibility of writing in different languages, with different alphabets without having to think for a moment …

  81. I did it my way » Blog Archive » Pimp my Blog 9. 6. 2005 / 17.40

    […] ines Artikels. Find ich klasse! Cat2Tag: Erstellt “Tags” aus den Kategorien. Polyglot: Ermöglicht das posten in mehreren Sprachen. OK, das geht auch so, aber dank dieses Plug […]

  82. FN 9. 6. 2005 / 20.43

    This looks like the missing-link I’ve been looking for – however Language Picker’s site give a 404 so I really don’t know how to install this. I’m a professional PHP coder so I could do it without a problem – but my issue is where do I put the file and what inclusions are required? Sorry to add to the list of “Help Me” posts malyfred – if you have time, your direction would be appreciated :)

    -FN-

  83. FN 9. 6. 2005 / 21.59

    Ok – I managed to get it myself – sorry for the premature plea for help. My only question left is the multi-lingual RSS Feed:

    http://nc.synergyxr.net/nema/feed/?lp_lang_view=en

    I see in “description” is shows both the lang-en and lang-de… should it show both like that or just the one for the language the client has selected? If that feed page is right, no worries, I’m just not familiar enough with XML to know.

    Thanks again,
    -FN-

  84. r0n 10. 6. 2005 / 11.40

    FN, you should add an excerpt (=description) filter to polyglot.php


    add_filter('the_excerpt', 'lang_picker_respect_more',1);

    then you´ll get proper localized RSS Feeds

  85. Younghusband 12. 6. 2005 / 8.31

    What would put the icing on the cake is if we could make a quicktag for Lang 1 Lang 2 etc, so that we don’t have to hand type each time. Any thoughts?

  86. r0n 12. 6. 2005 / 16.12

    Could be done by adding (for each language ISO) to your quicktags.js:

    edButtons[edButtons.length] =
    new edButton('ed_lang_xx'
    ,'lang_xx'
    ,''
    ,''
    );

  87. r0n 12. 6. 2005 / 16.14

    ahh, sorry, should be:

    edButtons[edButtons.length] =
    new edButton('ed_lang_xx'
    ,'lang_xx'
    ,'<lang_xx>'
    ,'</lang_xx>'
    );

  88. malyfred 13. 6. 2005 / 2.49

    >r0n&FN I’ve added this fix to the current version of Polyglot.

  89. Sylvain 20. 6. 2005 / 9.28

    >Younghusband

    Try this guide, it worked great for me!

  90. besorgt. » blog.start 24. 6. 2005 / 12.22

    […] nt in time. This blog is based on a slightly modified version of WordPress and the plugin PolyGlot by Martin Chlupac which permits multilingual entries.

    posted in the w […]

  91. Vito Tardia 29. 6. 2005 / 21.41

    […] ruenza nell’interfaccia, almeno fino a quando non avrò imparato a destreggiarmi con Polyglot e GetText. D’altra parte se fosse facile non sarebbe altrettanto divertente e vist […]

  92. Christoffer Soop » A Polyglot WordPress? 2. 7. 2005 / 22.01

    […] should thus be considered as a cross-cutting concern. Update: I just found out about the Polyglot plugin which seems to do the trick. Haven’t tried it yet, but it seems promising. […]

  93. seyd » Just colophoning my changelog 18. 7. 2005 / 9.18

    […] e the most recent and the two bottom ones are random. As for the languages I had installed Polyglot and worked out all the localizations ( thanks […]

  94. seyd » Just colophoning my changelog 18. 7. 2005 / 9.20

    […] e the most recent and the two bottom ones are random. As for the languages I had installed Polyglot and worked out all the localizations ( thanks Pankaj for that hi.mo file! ), but in the e […]

  95. Jiyul 23. 7. 2005 / 13.04

    Hey, thanks for what you did!
    but…
    is multingual rss works? I think yours dont work too.

    http://fredfred.net/skriker/index.php/feed/?lp_lang_view=en

    Am I miss understanding?

    please help me.

  96. z 23. 7. 2005 / 16.17

    i’m trying the plugin on a new photoblog and it does the job for me. however i’m following the instructions for the rss feeds, but besides the default language, the second language rss doesn’t work. the rss feed reader keeps spitting out errors. is there anything not listed here that i may have missed?

  97. micael 24. 7. 2005 / 6.36

    hi malyfred,
    Thank you very much for this plugin.
    It’s very usefull.
    unfortunatly, the list_cats of the translate-categories plugin don’t work …
    First I increase the number of allowed characters of “cat_name” in the database. (because titles were cutted)
    I try to touch this with no success:
    add_filter(‘list_cats’,’translate_link’);
    or add some _e() in my sidebar.

    I see list_cats translation of your site work.
    Can you give me a way of work please?
    Thanks.

  98. micael 24. 7. 2005 / 9.01

    hmmm, “cat_name” don’t allow html tags.
    so, something like cat_encat_fr
    will don’t work in “list_cats”. It’s sure…

  99. micael 26. 7. 2005 / 0.56

    I found the solution:
    I remove all the “wp_specialchars” relative to “cat_name” in wp-admin/categories.php

    for example:
    $cat_name = wp_specialchars($_POST['cat_name']);
    become
    $cat_name = $_POST['cat_name'];

    now, I have a HTML render inside my “wp_list_cats” and the polyglot plugin understand it.
    Coool.

  100. malyfred 26. 7. 2005 / 17.23

    >Jiyul&z I’m sorry that the instructions for RSS localization are not as clear as they could be. You have to use URL like this:
    http://addressofyourweb/?feed=rss2&lp_lang_pref=en

  101. Rauru Blog » Blog Archive » Polyglot 27. 7. 2005 / 17.31

    […] anohito on Thursday, July 28th, 2005 at 0:25 Now testing Polyglot, a plugin that enables to post in multiple languages. You can follow any […]

  102. Metabolik BioHacklab » Blog Archive » Wordpress multilingüe 28. 7. 2005 / 11.29

    […] a y castellano. Es muy f�cil! Hay que descargarse un plugin llamado Polyglot. El caso es que dicho plugin al parecer no contempla el idioma euskara (eu) as� que un co […]

  103. ptryk 1. 8. 2005 / 16.25

    ran into something i can’t seem to fix.. i am using a plugin to fix menu’s from pages..

    well.. when i am in a page, and if someone should change the language, .. it puts them back to the index page.. also i get a database error when using
    get_page_link() or get_permalink() used e.g…


    /?lp_lang_pref=en">[en]

    looks like the plugin can’t concoctenate?

  104. iLBorro’s blog » Wordpress multilingua? 3. 8. 2005 / 12.18

    […] post possa essere sia in italiano che in inglese? La cosa sembra essere semplice grazie a questo plugin. Lo proverò, e vi terrò informati Nessu […]

  105. freshlabs — Wordpress multilanguage 6. 8. 2005 / 11.26

    […] Bislang habe ich zwei davon ausprobiert: Polyglot (Autor URI: http://fredfred.net/skriker/index.php/polyglot) Polyglot erlaubt es, die Sprache in einem Post mi […]

  106. malyfred 9. 8. 2005 / 22.58

    >ptryk Don’t forget that you cannot use: ?lp_lang... with any kind of mod_rewrite or permalinks:(

  107. Netlex News » Blog Archive » test 16. 8. 2005 / 21.17

    […] test Internationalisation Basic bilingual : installed Multilingual Polyglot This entry was posted on Tuesday, August 16th, 20 […]

  108. dan 21. 8. 2005 / 14.33

    wow, great plugin! just what I want :-), Great Thanks!

  109. Valet och kvalet… at Spacewaster 24. 8. 2005 / 15.35

    […] Uppdatering: Gjorde en snabb sökning, och hittade Polyglot, ska kolla bättre hur det fungerar i morgon. […]

  110. Bilingual at Spacewaster 24. 8. 2005 / 21.40

    […] I’ve now installed the Polyglot plug-in, but there’s some problems as you might see… I’m working on a solution. […]

  111. Len » Blog Archive » Kadishtu 1.1 31. 8. 2005 / 12.57

    […] Je teste un plugin d’i18n appellé Polyglot donc j’ai inclus une barre de menu de langage au thème et fait d’autres petits changements. […]

  112. Bilingual at Spacewaster 6. 9. 2005 / 12.48

    […] now installed the Polyglot plug-in, but there’s some problems as you might see… I’m working on a solution. Jag har nu installerat Polyglot, men som du kanske mker r det liteproblem… jobbar med felskningen.   #     […]

  113. Fixed the language 9. 9. 2005 / 9.04

    […] Fixed the language, found out that it was a clash between Polyglot and PreFormatted, sadly Polyglot doesn’t work with my “Besides” blog-thingy. Have to look into that. Found another “clash”, Brian’s Latest comments didn’t want to translate… […]

  114. Fairweb 16. 9. 2005 / 10.36

    Adaptation et adoption du plugin Polyglot

    On m’a demandé d’adapter le bilinguisme sur un site réalisé avec WordPress. Inutile de réinventer le monde. WordPress est open source et on ne développe des plugins que lorsqu’on ne les trouve pas ailleurs. J’ai testé plu…

  115. Agaponeo's 18. 9. 2005 / 18.58

    Problems with language

    Thanks at the plugin of malyfred for WordPress, now I can write in some languages, so the people can read in his language.
    But I think in this way I will get more confused with the languages, that I already get always confused with them (who meet me, …

  116. Agaponeo 19. 9. 2005 / 10.41

    HI.. thanks for this plugin…
    But I can’t get working the translate categories… really I don’t know how translate them… (the archives works well)
    and in the side bar… the tags doesn’t work for me :(…
    any clue?

    thanks again for this plugin :)

  117. malyfred 19. 9. 2005 / 13.08

    Agaponeo> Tags in the sidebar seem to be ok. They look like they should and they work for me. Only problem I have noticed is that you’ve left some spaces or UTF BOM in the polyglot.php so you get warning at the very begining of every page.

    Translate categories plugin is very unreliable because it works in a very dirty way and probably only with wp_list_cats():( Unfortunately I have not found better way yet.

  118. Trackback 19. 9. 2005 / 13.19

    Trackback: http://dongchimi.org/wp/?p=20

  119. El Rincón de Boriel » Boriel’s blog goes bilingualEl blog de Boriel se vuelve bilingüe 19. 9. 2005 / 14.00

    […] Now, and thanks to the polyglot plugin for WordPress, this site will be (whereever possible) in both languages, English and Spanish (and apologies for English grammar/spell mistakes ). […]

  120. Agaponeo 19. 9. 2005 / 19.42

    Sorry.. I made some mistake.. can you delete the upper post? :)

    Thanks… but… the warning was for another plugin conflict that I resolved…

    The thing may be is that in the sidebar there is no this code –?php if(function_exists(‘lp_other_langs’)) {
    //display existing language versions of the post
    lp_other_langs(‘ ‘,”, ”, ”, ”);
    }?–

    do you think that can be that…?

    (sorry my english)

  121. malyfred 19. 9. 2005 / 20.16

    Dear Agaponeo, I have checked your site twice and it looks exactly as it should. And it even works!:) So what is exactly your problem? What kind of different behaviour do you expect?

  122. Agaponeo 21. 9. 2005 / 10.17

    Sorry… for bother you…
    I wanted to be able to change the language in the sidebar, just some small content.

    But no problem. and like always thanks for the plugin.
    (is a little tyring write in many languages :S )

    bye bye

  123. malyfred 21. 9. 2005 / 12.18

    Agaponeo> Maybe I’ve got it finally – you want to have some ‘content’ in the sidebar in different languages? Easy!

    1) ‘gettext’ it: _e('some text');

    2) add this translation into your .mo files

  124. Marc 22. 9. 2005 / 9.49

    Hello malyfred,

    first off, thanks for creating the currently only stable multilingual extension to WordPress. It has already helped me a lot. :-)

    One thing bothers me, tho – not being able to translate page titles yet. “translate-categories” works great, I just wished it would also do so for pages. Do I understand correctly that it cannot work because WordPress doesn’t offer an appropriate filter hook for wp_list_pages? Does the WordPress beta version do so, or do you have any other idea to solve that?

    Thanks for your help,
    Marc

  125. malyfred 22. 9. 2005 / 11.56

    Marc> Add this hook to your plugin:

    add_filter('wp_list_pages', 'lang_picker_respect_more',1);

    or re-download Polyglot. It’s not perfect because titles of genereated links stay untranslated, but…

    You can now translate page titles in exactly same way as post titles.

    example:
    <lang_en>English title</lang_en><lang_cs>Český název</lang_cs>

    It doesn’t look translated in administration (WP bug) but it works fine on the final page.

  126. Marc 22. 9. 2005 / 16.33

    Well, that’s a start, thanks indeed! :-) Translating the links as well will require a new WordPress core filter hook, right? Like that I’d have already created a “translate-cats-and-pages” plugin… ;-)

    Regards,
    Marc

  127. Secretservices Performance Blog 22. 9. 2005 / 18.49

    Mehrsprachig….Polyglot

    Um mein Blog mehrsprachig anzubieten, habe ich auf das Plugin Polyglot zurückgegriffen. Das funktioniert für die Artikel, wie hier wohl auch zu sehen, recht gut. Das Manko liegt darin, daß die Menüleiste nicht genauso einfach übersetzt werden kan…

  128. Agaponeo 22. 9. 2005 / 20.24

    thanks for your patient.. and for undestandme what I wanted…
    sad is that I Think I can’t exec, i tryed some code that I find but the wordpress gettexec page didn’t really helped…

    Another thing.. Nice the new plugin ;)

  129. malyfred 23. 9. 2005 / 0.00

    Marc> Could you test the latest version of Polyglot? You don’t need any plugin for translating categories/pages anymore. But for links… yes, you are right, we need a new hook:(

  130. Agaponeo 24. 9. 2005 / 2.32

    I think I’m annoying… :)
    well Thanks for averyting and for this awesome plugin…
    I manage everything… (Is just some time to learn code ;) ). I get well with gettexec now… and how to edit po, pot & mo files… so now I have my traductions how I like them :)

    Sincerly Thank you again.

  131. Vito Tardia 29. 9. 2005 / 14.02

    […] Siccome ho intenzione di scrivere sia in inglese che in italiano, è probabile che ci sia qualche incongruenza nell’interfaccia, almeno fino a che non sarò riuscito a integrare al meglio Polyglot e GetText. Lo sapevo che dopo i primi esperimenti su Blogger la mi curiosità mi avrebbe diretto verso WordPress. Quindi, visto che da qualche parte si deve pur cominciare, ho comiciato con l’installarlo e pasticciare un po’ con il codice…stupendo! Leggi » […]

  132. Marc 29. 9. 2005 / 22.18

    malyfred,

    Pages work fine, thank you, but without the links it’s not really enough for me yet. Anyway, thanks for confirming my suspicions – I’m still quite of a WP-n00b, so that helps my ego a little. ;-)

    Marc

  133. Goulven 30. 9. 2005 / 19.50

    Excellent plug-in. I use it for my site in english, french and arabic. I have a problem with arabic because the tag at the beginning of the page must have the dir=”rtl” parameter when other languages must have dir”ltr”.

    Is it possible to complete the plug-in with this parameter?

    Thanks and thanks again for your plug-in!

  134. malyfred 30. 9. 2005 / 23.59

    Goulven> If I understand the concept of ‘ltr’ and ‘rtl’ codes – it must be specified in <html> tag and that cannot be done automaticaly because there is no WordPress hook for that.

    But you can put this code to your header.php file:


    <html

    <?php
    if(polyglot_get_lang() == 'ar'){
    echo 'dir="rtl"';}
    ?>
    >

    Don’t forget to re-download Polyglot.zip because polyglot_get_lang() function has been added recently.

  135. malyfred 3. 10. 2005 / 23.03

    ALL> I’ve noticed the WP/PHP bug in WP 1.5.2 and PHP 4.4.0. You have to fix gettext.php like this:

    //$MAGIC1 = (int)0x950412de; //bug in PHP 5
    //$MAGIC1 = (int) - 1794895138; //bug in PHP 4.4.0
    $MAGIC1 = 2500072158;

    //$MAGIC2 = (int)0xde120495; //bug
    //$MAGIC2 = (int) - 569244523;// bug in PHP 4.4.0
    $MAGIC2 = 3725722773;

  136. Goulven 4. 10. 2005 / 9.33

    malyfred> Thanks, it’s working!

  137. Tom 13. 10. 2005 / 15.17

    I searching a way to translate categories in the RSS . Content of the post is correctly translated but not the categories… I tried some add_filter but no ways :(
    Any ideas ?

    PS: I updated my polyglot.php (don’t what had change) but I updated ;) I ought be nice to recall this version 0.5 because there is approx more than 100 new lines. But I understand that you’re probably overbooked.

    Always a great work/job! Thanks!
    Tom

  138. Tom 13. 10. 2005 / 15.50

    I have consider a bit and here is the solution.
    Just add these following line to your translate-categories.php :


    function translate_the_category_rss($text){

    return preg_replace_callback('/()(.*?)()/i','translate_callback',$text);
    }
    add_filter('the_category_rss', 'translate_the_category_rss', 1);

  139. malyfred 13. 10. 2005 / 17.33

    Tom> Thank you! I’ve added this fix to “official” version. But this version should be enough:


    add_filter('the_category_rss','__',1);

  140. Mateusz Łoskot 15. 10. 2005 / 5.17

    Hi,

    First, thanks guys for your great work and Polyglot plugin.

    Here is my small customization I called “Polyglot with flags” (down on the page):

    http://mateusz.loskot.net/projects/wordpress/

    and it displays small flags instead of text label to indicate what languages are available for some post/page.
    You can configure it to use flags or text labels.

    I believe Martin you don’t mind I put it on my page to download :-)

    I added a few lines of code and big set of flags from http://www.crwflags.com/fotw/flags/wflags20.html (with minor file names customization).
    More information is availabile in my comments in the code and README.txt file in archive on my website.

    I also have some problem, but I think it is a general problem or I don’t underdstant something :)
    Here is one of my posts in polish language and there is no english content for it, only polish, but as you see there is english flag (or text label) as available language:
    http://mateusz.loskot.net/2005/10/15/jak-warszawska-straz-miejska-kleka-przed-j-oleksym/

    I have defined english as my default language, but I expect that if I put some post only in polish then only polish flag is visible. Am I right?

    Could you explain me this behaviour?
    What exactly default language means? Browser language or WP language?
    Cheers

  141. Tomkun 15. 10. 2005 / 6.35

    I downloaded this plugin yesterday and have got it working (mostly), but I have a problem when using it with firefox.

    In IE, everything is as it should be and when I navigate to a page, it remembers the language settings.

    But in firefox, when navigating to a page it ‘forgets’ what language it should be in and goes back to English. Anybody know of a fix for this? I am assuming it’s not a problem because it works fine in IE. It’s just that I personally use Firefox and it’s a pain in the bum!

    You can see what I mean here
    http://www.tensamurai.com

    Thanks :-)

  142. Tomkun 15. 10. 2005 / 7.18

    Oops! Never mind about that last request… It was my error!

  143. Tensamurai 15. 10. 2005 / 9.07

    Language

    Today, I spent a lot of time making sure that the different language interfaces work. Now the site is available in English and Japanese. It took a really long time to get everything working the way I wanted it to, but now I am fairly happy with it. …

  144. Tensamurai » Blog Archive » Language言葉 15. 10. 2005 / 9.11

    […] right now! The plugin is available from here. Posted by Tomkun under General | Permalink | Trackback | « English!| […]

  145. Mateusz Łoskot 15. 10. 2005 / 17.19

    About problem described in my comment #140

    So, here is step-by-step desc of my problem.
    May be someone will be able to give a piece of advice.

    1. My Firefox has selected polish language as default (first on languages list in FF configuration). I have also selected english (placed on the langs list below polish).

    2. English is default language for my WP installation

    3. Most of my blog posts are in english and very few in polish

    4. Example of post in polish in my blog:
    http://mateusz.loskot.net/2005/10/15/jak-warszawska-straz-miejska-kleka-przed-j-oleksym/

    5. What is wrong in my opinion?
    Why there is english flag below title header of my post in polish? I have no .. block of content, only …

    Here is another post which is available in both langauges: polish and english:

    http://mateusz.loskot.net/2005/08/22/welcome-to-the-jungle/

    and certainly it works perfectly, I see polish version and english flag, but when I see english version I have polish flag.

    The question is:
    Why I have english flag for post which is available ONLY in polish?

    Thanks for any help

  146. malyfred 16. 10. 2005 / 0.06

    Mateusz Łoskot> That’s a bug and I’ve fixed it in “official” version. Thanx for report.

    Btw I consider “taging” of one language posts as very problematic, because you get empty post if your default language and currently selected language are different than the language of the post. I wouldn’t recommend you doing that.

  147. Mateusz Łoskot 16. 10. 2005 / 0.31

    malyfred> I understand. Yes, I see having only one lang of post is a bit problematic, but I think it shouldn’t be difficult to solve. I’ll try to look at this but now I have not much time :-(
    Where I find official version? I could put this fix to my Polyglot-with-flags ;-)
    BTW, what do you think about my customization of Polyglot?

  148. malyfred 16. 10. 2005 / 1.10

    Mateusz Łoskot> Official version ~ re-download it from this page.

    One version language “issue” is actually quite difficult to solve as there is no obvious expected behaviour. Some people prefere current behaviour (as I do), some other would expect some text shown all the time. This problem gets bigger with two, three,… languages when the default language version is not present. Which version is the right one then?

  149. Mateusz Łoskot 16. 10. 2005 / 3.15

    malyfred> This problem gets bigger with two, three,…languages when the default language version is not present.

    Yes you’re right, I’m convinced.

    malyfred> Which version is the right one then?

    What do you mean? Version of what?

  150. malyfred 16. 10. 2005 / 19.42

    Mateusz Łoskot> Language version…:)

  151. Mateusz Łoskot 16. 10. 2005 / 21.33

    malyfred> Mateusz Łoskot> Language version…:)

    Oh, I see ;-)
    English is default language for my website.
    But as you suggested, I decided provide both versoins – pl, en – and i.e. if some of my post is in polish then I put short information as here:
    http://mateusz.loskot.net/2005/10/16/napisalem-do-oleksego/

    Not very elegant, but does not confuse users.

    And what about polyglot-with-flags?

  152. malyfred 17. 10. 2005 / 2.16

    Mateusz Łoskot> Well, I haven’t found any useful information about copyright of these flags.

    I take your version as a kind of “suggestion” what could be implemented to Polyglot in next version. Let me know if you have details about flags copyright issue.

  153. jesse 18. 10. 2005 / 20.54

    hey Malyfred et al!
    thanks for such a useful blogging tool. The only thing that’s really driving me crazy is that only some of my page titles respond to the tags. Some work, others don’t.. Any ideas/suggestions?

  154. malyfred 18. 10. 2005 / 22.27

    jesse> Do you use the latest version of Polyglot?

  155. jesse 18. 10. 2005 / 23.19

    yes, i believe so. The one linked up top, correct? I also followed your advice in post 125 and added the following hook:

    add_filter(‘wp_list_pages’, ‘lang_picker_respect_more’,1);

  156. malyfred 18. 10. 2005 / 23.51

    jesse> Re-download it now just to be sure. There have been many things done about pages and related stuff recently and I’ve released new version (0.6) today.

    Which parameters do you pass to your wp_list_pages()?

  157. jesse 19. 10. 2005 / 0.30

    i just re-downloaded it, to no avail. I’m not sure where to check on which parameters i pass to my wp_list_pages()
    I’m only moderatly familiar with PHP/wordpress, I’m afraid! I realize that you put up a disclaimer regarding us newbies using this pluggin, but I am very grateful for your help.

  158. malyfred 19. 10. 2005 / 0.42

    jesse> You are calling wp_list_pages() somewhere in your theme. And there is some “stuff” between brackets. I’d like to know this stuff to be able to simulate it on my server.

  159. jesse 19. 10. 2005 / 0.50

    i see. I’m using the blix theme and haven’t made any significant changes: http://www.kingcosmonaut.de/blix/

    Hopefully you’ll find some answers there..

    Or is there anywhere I should be looking in particular? Like the Index.php page or something?

  160. malyfred 19. 10. 2005 / 14.14

    jesse> There are about 10 files in the theme… is it that hard to check all of them?

  161. jesse 20. 10. 2005 / 0.18

    ok! I finally found it in the sidebar.php page. It is coded as follows:

  162. jesse 20. 10. 2005 / 0.20

    In between the brackets after wp_list_pages is written: ‘title_li=&sort_column=menu_order&exclude=’.$excluded

  163. malyfred 20. 10. 2005 / 1.11

    jesse> That seems ok:( Have you tried to deactivete all other plugins? It could be some plugins collision.

  164. jesse 20. 10. 2005 / 3.20

    yeah, i tried that :(

    I’m afraid it may just be over my head, but I’ll keep digging for an answer. Thanks for taking a look at it!

  165. Mateusz Łoskot 23. 10. 2005 / 0.51

    Hi malyfred!
    I sent some quoestions about copyrights of flags I use in my Polyglot customization.
    Here are two responses I got from Rob Raeside from FOTW (http://www.crwflags.com/fotw/)

    Here for my first question for copyrights explanation:

    ###########################################
    Hi Mateusz,
    You are welcome to use the images from FOTW provided you don’t end
    up selling them (i.e. “no commercial use”). For open source purpose,
    all we ask is that the source of the images be provided in the acknowledgements areas.

    Rob Raeside
    Director, Flags of the World,
    Wolfville, Nova Scotia, Canada
    http://flagspot.net

    ###########################################

    and second for more details about that acknowledgements:

    ###########################################
    Hi again, Mateusz,
    You should indicate something along the lines of “all flag images
    courtesy of FOTW (http://flagspot.net). For re-use of images, please
    see http://flagspot.net/flags/disclaim.html.”

    I can’t guarantee every image on FOTW is owned by FOTW for copyright
    purposes, but certainly all the national and state ones are. So
    unless you re-use an image that states it was provided by a third
    party, you would be OK with this statement.


    Rob Raeside
    Director, Flags of the World,
    Wolfville, Nova Scotia, Canada
    http://flagspot.net
    ###########################################

    So, what do you think now about flags in Polyglot?

  166. malyfred 23. 10. 2005 / 10.54

    Mateusz Łoskot> I’ve already implemented this “flag feature” as a part of big refurbishment of Polyglot’s code last week.

    I’ve used flags from GPL project http://www.phpmyvisites.net/

    But thank you for your idea and work!

  167. Mateusz Łoskot 23. 10. 2005 / 16.09

    So, are you going to release Polyglot with those flags from phpMyVisities?
    I’m strongly interested.

  168. malyfred 23. 10. 2005 / 19.36

    Mateusz Łoskot> Download Polyglot ver. 0.6 and you’ll see the flash of the future:))

  169. Tomkun 24. 10. 2005 / 13.35

    Help!

    I am having serious trouble with this plug-in. Every time I try to switch to Japanese, I get this error:

    Fatal error: Cannot instantiate non-existent class: cachedfilereader in /home/tensamur/public_html/wp-includes/wp-l10n.php on line 72

    I didn’t used to have this problem, but it suddenly sprung up.

    I have reinstalled WordPress, and the latest version of Polyglot (0.6), but I still can’t solve it.

    Anybody got any advice?

  170. Tomkun 24. 10. 2005 / 13.46

    Oops…

    Sorry to waste your time. I edited the wrong file.

    wp-settings.php instead of wp-config.php

    SORRY! It’s all working perfectly now!

  171. Djuki 26. 10. 2005 / 23.07

    
    Warning: Cannot modify header information – headers already sent by (output started at /home/djuki/public_html/djuki/blog/wp-content/plugins/polyglot/polyglot.php:1) in /home/djuki/public_html/djuki/blog/wp-admin/admin.php on line 10

    Warning: Cannot modify header information – headers already sent by (output started at /home/djuki/public_html/djuki/blog/wp-content/plugins/polyglot/polyglot.php:1) in /home/djuki/public_html/djuki/blog/wp-admin/admin.php on line 11

    Warning: Cannot modify header information – headers already sent by (output started at /home/djuki/public_html/djuki/blog/wp-content/plugins/polyglot/polyglot.php:1) in /home/djuki/public_html/djuki/blog/wp-admin/admin.php on line 12

    Warning: Cannot modify header information – headers already sent by (output started at /home/djuki/public_html/djuki/blog/wp-content/plugins/polyglot/polyglot.php:1) in /home/djuki/public_html/djuki/blog/wp-admin/admin.php on line 13

    I have this errors after instaling new version of this plygin. Can u hel me ?

  172. malyfred 27. 10. 2005 / 0.35

    djuki> You have obviously left some characters before <?php when you were editing polyglot.php. This can be even just UTF-8 BOM. You should use UTF-8 compliant editor where you have to turn the BOM off.

  173. Djuki 27. 10. 2005 / 11.21

    No i did not left caracters before

  174. Djuki 27. 10. 2005 / 11.24

    No i dod not lef some characters before php

    Warning: session_start(): Cannot send session cache limiter – headers already sent (output started at /home/djuki/public_html/djuki/blog/wp-content/plugins/polyglot.php:1) in /home/djuki/public_html/djuki/blog/wp-content/themes/Blue_Radiant/index.php on line 3

    I use sessions in mz blog, can thet be problem.

    And i use windows-1250 charcter coding.

  175. Erik 1. 11. 2005 / 23.43

    I’m having some trouble with this plugin. I have uploaded the .mo files to the /wp-includes/languages/ directory, so that should be ok, and the other files needed (I think anyway, I uploaded the files in the downloade zip to the plugins directory, and it shows up in the admin panel).
    I added this piece of code to the php files,
    ', '', '', '');
    }?>

    but nothing happens. I’ve translated one post, but when I click the flag I get the post without my translation again. Do I have to add more code, did I add it in a wrong way or could I have made any other mistake? I’m not that sure just where to add it in the templates, but I have added it anyway.

  176. Erik 1. 11. 2005 / 23.47

    Oops, the code didn’t show up very well.

    ‘, ”, ”, ”);
    }?>

  177. Erik 1. 11. 2005 / 23.49

    Sorry, please delete that… anyway it was the code you provided above, after:
    If you put to your index.php (and single.php, search.php etc.) in your themes something like this:

  178. malyfred 2. 11. 2005 / 0.22

    Erik> It seems that you have set $polyglot_settings['lang_rewrite'] = true; haven’t you?

    Turn it off and let me know.

  179. Tomkun 2. 11. 2005 / 13.41

    Is there a way of getting this to work with the folding page menu plugin? I tried that and it appears broken (It displays both languages). I guess it would be a simple fix for those with a talent at this sort of thing, but unfortunately, I am not one of them!

  180. malyfred 2. 11. 2005 / 14.36

    Tomkun> Send me a link to that plugin and I’ll check it.

  181. Erik 2. 11. 2005 / 23.12

    Thanks malyfred, I had. I turned it off and now it works alright. Just one thing though, now it shows up like a vertical list below the title of the post. Can you tell me how to take away the list-thing and put it on the same line as the title?

  182. malyfred 2. 11. 2005 / 23.51

    Erik> Use:

    .inlinetitle ul {display: inline;}

    in your CSS file or call the function for generating of this list without list tags:


    <?php if(function_exists('lp_other_langs')) {
    //display existing language versions of the post
    lp_other_langs(' ',' ', ' ', ' ', ' ');
    }?>

  183. IImage Browser | skriker 3. 11. 2005 / 0.11

    […] Polyglot […]

  184. IImage Gallery | skriker 3. 11. 2005 / 0.14

    […] Polyglot […]

  185. Tomkun 3. 11. 2005 / 3.30

    OK, here’s the link…
    http://www.webspaceworks.com/resources/cat/wp-plugins/30/
    If you can get it to work, I will be forever in your debt!

  186. malyfred 3. 11. 2005 / 13.45

    Tomkun> Try to replace:

    $page_tree[$page->ID]['title'] = $page->post_title;

    in fold_page_list.php

    with:

    $page_tree[$page->ID]['title'] = apply_filters('the_title', $page->post_title);

    I haven’t tested this fix but it should work.

  187. Erik 3. 11. 2005 / 23.59

    Thanks again, works good now.

  188. Tomkun 4. 11. 2005 / 1.32

    Thanks so much, that works perfectly. You are indeed a superstar.

  189. Thomas Augustsson 6. 11. 2005 / 18.07

    I got really excited when I read about this plugin but I cant download it. Neither the original link or the mirror seem to be able to provide the file for me. Can anyoune mail or point to another source for the file so I can evaluate the plugin, it could be just what I am after.
    Thanks!

  190. Steven Greenwood 7. 11. 2005 / 19.12

    I also had the “Warning: Cannot modify header information” error

    Solution: Use a UTF-8 editor like SuperEdi (http://www.wolosoft.com/en/superedi/)
    I was using Notepad

  191. malyfred 7. 11. 2005 / 19.21

    Djuki> You can use Win-1250 as you want, but polyglot.php (and the rest of WP) is saved in UTF-8. So try to use Steven’s suggestion and edit polyglot.php with SuperEdi.

  192. Steven Greenwood 8. 11. 2005 / 13.05

    malyfred, I am having trouble with the rewrite, that you describe in the polyglot.php. i.e.
    RewriteRule ^(.*)/xx/?$ /$1?lp_lang_view=xx [QSA]

    I have added:
    RewriteRule ^(.*)/de/?$ /$1?lp_lang_view=de [QSA]e
    to my .htaccess.

    I am using the standard Permalink Structure:
    /%year%/%monthnum%/�y%/%postname%/
    However the ‘deutsch’ link still resolves to:
    fluxmedia.de/?lp_lang_pref=de&page_id=6
    any ideas?
    thanks

  193. malyfred 8. 11. 2005 / 13.44

    Steven Greenwood>
    Have you set:

    $polyglot_settings['lang_rewrite'] = true; ?

    I’m not allowed to use mod_rewrite on my webhosting so I cannot test it:(

  194. Steven Greenwood 8. 11. 2005 / 15.07

    Yes, looks like this:
    $polyglot_settings[‘lang_rewrite’] = true;

    RewriteRules look like this:
    RewriteRule ^(.*)/de/?$ /$1?lp_lang_view=de [QSA]
    RewriteRule ^(.*)/en/?$ /$1?lp_lang_view=en [QSA]

  195. malyfred 8. 11. 2005 / 20.52

    Steven Greenwood> Re-download polyglot.zip because I’ve added some code related to this issue.

    I think that the main problem is in the RewriteRules… WP is using now a complicated system or generated rules and you should add more rules than just two and these should be more sophisticated. I cannot help you with this because I’m not allowed to use mod_rewrite on my server:( Try to ask your admin for help.

  196. trevor 9. 11. 2005 / 0.36

    This is a great plugin, but I’d just like to follow up Diego’s point of 10/4/2005. He’s having the same problem I’m experiencing: turning on the plugin overrides the localization choice of the administration interface, imposing English. Is there any way to use the plugin without doing this?

  197. trevor 9. 11. 2005 / 0.41

    Sorry for the stoopid question, just realised the answer was below D’s query. Thankyou…

  198. PDLib Blog » Bienvenidos! 10. 11. 2005 / 0.59

    […] Postear en varios idiomas Technorati Tags: PDLibBlog Tags […]

  199. MoebiuZ 11. 11. 2005 / 8.39

    Hi malyfred!

    I have found 2 little problems in Polyglot.

    If you click over a categorie (translated with tags) in the Title bar of the navigator you see:

    TitleTtle

    If you do same clicking over the title of a post, then you get in the title bar:

    TitleTitle

    There is any solution for that?

    You can see the problem here.

    Thx

  200. MoebiuZ 11. 11. 2005 / 8.41

    In the first example I mean

    lang_enTitle/lang_en lang_xxTitle/lang_en

  201. Daniele 11. 11. 2005 / 16.07

    I have a problem
    because I installed Chen press to have an editor
    but If I write the code:
    prova

    when I save It has coverted in:
    prova

    so the plugin don’t work

    If I desactive chen press it goes
    have you any suggestion?

    DANIELE

  202. malyfred 12. 11. 2005 / 16.07

    Daniele> If you know PHP at least a bit – then you can switch from <lang_xx> to and it will work fine. But you have to rewrite few lines in the polyglot.php.

  203. malyfred 12. 11. 2005 / 16.20

    MoebiuZ> Find this code:


    if (is_single() || is_page()) {
    $title = strip_tags( $posts[0]->post_title );
    $title = apply_filters('single_post_title', $title);
    }

    in template-functions-general.php to:


    if (is_single() || is_page()) {
    $title = $posts[0]->post_title;
    $title = apply_filters('single_post_title', $title);
    $title = strip_tags($title);
    }

    I haven’t experienced such error when selecting category.

  204. Daniele 14. 11. 2005 / 18.04

    Thank you
    I have desactived Chen Press
    then I’m going to find another editor (what do you use??)

    Your plugin is ideal for a multilanguage blog

    I have only a little problem

    some flags doesn’t want to appear:

    http://www.ottonovedue.com/wordpress/

    have you any ideas about?
    Thanks Daniele

  205. Daniele 14. 11. 2005 / 18.05

    and then
    I’am italian how can I set my language to default

  206. malyfred 14. 11. 2005 / 19.18

    Daniele> Open polyglot.php and you’ll see the answers to all your questions. You have to edit:

    $polyglot_settings['default_lang']

    and add

    $polyglot_settings['flags']['xx']
    $polyglot_settings['trans']['xx']

    for languages that are not specified yet.

    The most of languages are missing because I don’t know how they are called. E.g. “Portuguese” in Portuguese:) And also some people would prefer to have Brazilian flag for Portuguese instead of Portuguese flag etc.

  207. Daniele 15. 11. 2005 / 11.00

    Great

    Thank you very much
    in the next days I will try to insert yor plugin in other part of my blog

    Daniele

  208. Pierre 15. 11. 2005 / 12.16

    Very nice plugin, but I have 2 problems (I’m 100% newbie, though):

    1. I’m unable to implement the language picker in index.php. Somehow the post’s title disappears and my sidebar is pushed to the bottom (I’m using the default template, by the way).

    2. I was able to put the language picker on my sidebar, but it looks like the selection is not kept in memory. Example: I’m on the homepage, I select “french”. The posts display in french, as expected. Now I click on a post’s title and in “post view” (or whatever you call it), the post is still in french. BUT if I now click on my blog’s title to go back to the main page, the posts are displayed in the default language again (instead of french).

    Any help would be much appreciated.

    P.S. As a sidenote, can I install the plugin within a subfolder of the plugins folder? All of my plugins are in the root “plugin” folder and it’s getting confusing. + can I do the same with all plugins (i.e. install them in their separate subfolder)?

  209. malyfred 15. 11. 2005 / 13.58

    Pierre> Let’s start from the end – yes, you can install plugins in the subfolders.

    2. The selection is saved in cookie so there could be problem with settings in your browser or collision with some other plugin (don’t you use some caching plugin?)

    1. This is strange – send me a link to that page.

  210. Daniele 15. 11. 2005 / 15.41

    It’s very strange

    the setup of my wordpressblog is in italian language but when I active your plugin It return in english

  211. Pierre 15. 11. 2005 / 16.47

    Thanks for your quick reply, malyfred!

    1. Language selection using sidebar:

    I’m using the following other plugins:
    Adhesive
    Event Calendar
    Registered Only
    Subscribe2
    iimage browser (now deactivated)
    (and of course Polyglot)

    I deactivated iimage browser, because it doesn’t work properly (I suspect my company browser doesn’t accept javascript and this is the reason it doesn’t work).

    2. Language selector within index.php:
    Where exactly should I paste this code?
    ‘, ”, ”, ”);
    }?>

    I’m sending you testuser account credentials by mail, as well as my index.php prototype which doesn’t work.

  212. malyfred 15. 11. 2005 / 20.36

    Daniele> Because Polyglot takes over the language settings… you should read Comment #206 more carefully.

    It also depends on your browser language settings because Polyglot respects the main language set in the browser as your prefered one.

  213. Thomas 15. 11. 2005 / 20.54

    Hi! The plugin works wonderful. Merci!

    I have merely some remaining problems with the PAGE titles. There is no problem if I use OrganizationsOrganisationen but it does not understand my changes in the po/ mo file (which works fine with hte categories, e.g. wp_list_pages).

    Any idea?

    Cheers, Thomas

  214. Thomas 15. 11. 2005 / 20.56

    ups, OrganizationsOrganisationen refers to

  215. Thomas 15. 11. 2005 / 20.58

    last trial: lang-tag

  216. malyfred 15. 11. 2005 / 20.59

    Pierre> I’ve checked your site and everything works fine!

    When you pick from the language offer in the sidebar – then the selection should be saved in the user’s cookie and he gets content in this language until he selects another one. It works for me so you should check your browser’s cookie settings.

    Also the languages offered for every post work fine. When you pick from this offer it just shows the post in selected language but this choice is not saved!

    And to answer your last question from your e-mail – Comments #85+86

    The only strange thing is that you have turned off $polyglot_settings['lang_change_locale']. Any special reason to serve french content surrounded by english “garbage”:)?

  217. malyfred 15. 11. 2005 / 21.08

    Thomas> Page titles can be translated only with <lang_xx>One version</lang_xx> <lang_yy>Another version</lang_yy>

    I’ve explained why category names must be translated in .mo file in “How to translate categories” paragraph of the post.

    btw. these characters – < and > must be written like &lt; and &gt; :)

  218. Atun tun tun… » Probando plugin Polyglote 15. 11. 2005 / 22.49

    […] – Se llama Polyglot y lo he descubierto gracias a Zootropo que lo recomendó en un comentario. – Estoy aún probándolo y modificándolo un poco para que aparezca a mi gusto – Haré un mini-how-to para los que quieran ponerlo en su blog, dado que, aunque en la página oficial del plugin lo explican bastante bien, seguro que hay alguno que no tiene ni idea de PHP ni de inglés, así que lo haré por esas almas cándidas – No es nada complicado escribir en dos idiomas, se hace al escribir la propia entrada. Ya vereis ya.. – Aun no sé como aparece en la sindicación, tendré que investigar más. […]

  219. Weblog de WiZaRd_ » Weblog (casiquasi) bilinge 16. 11. 2005 / 5.12

    […] Debido a una entrada en la que Manuls admita que le haba entrado el gusanillo de hacer su weblog bilinge, al estilo de David Martinez, yo haca un comentario en el que deca que a m tambin me gustara hacerlo (en valenciano y castellano), al cual Zootropo contesta aconsejndonos usar el plugin Polyglot. […]

  220. Daniele 16. 11. 2005 / 10.34

    I precise

    Your plugin goes very well

    I changed the parameters in 206

    but I use wordpress with a localization file in Italian .mo
    and when I active your plugin the language of administration and blog returns in english

    if I desactive the plugin every part returns in Italian

    I use a bowser in italian and I have tried to use all cod

  221. Pierre 16. 11. 2005 / 11.57

    Thanks a lot for your support, Martin. What do you mean by:
    “The only strange thing is that you have turned off $polyglot_settings[‘lang_change_locale’]. Any special reason to serve french content surrounded by english “garbage”:)?”

  222. Pierre 16. 11. 2005 / 11.58

    I checked the code and it is set this way:
    $polyglot_settings[‘lang_change_locale’] = TRUE;
    What’s wrong?

  223. malyfred 16. 11. 2005 / 15.43

    Daniele> That must be just some mess in your language settings. Check twice wp-config.php and polyglot.php if everything is all right. Don’t forget that your language files must be called “xx.mo” e.g. “it.mo” and you have to set your default language also as xx not xx_XX.

  224. malyfred 16. 11. 2005 / 15.46

    Pierre> So you don’t use french localization file (fr.mo)!

  225. Daniele 16. 11. 2005 / 16.23

    Thank you Malyfred

    localization file called it_IT
    so you plugin didn’t know it

    now it is all good
    thank again

  226. Pierre 16. 11. 2005 / 17.35

    Ah! No, I’m not using a localization file (I’m not that far yet). ;-)

    Concerning the language setting using the sidebar, it’s apparently not a cookie problem (I’ve checked and cookies do work). If I refresh my browser window, I get the correct result, so it rather appears to be related to the way WordPress’ cache works. Any idea if there’s a workaround? Perhaps disable caching in WP? Don’t know how to do that, though.

  227. malyfred 16. 11. 2005 / 19.25

    Pierre> WP doesn’t have any caching system by default and your page works for me so…

    Try to change language of this page in the sidebar – does it work?

  228. Atun tun tun… » Polyglot: Mini-how-to 16. 11. 2005 / 22.29

    […] Polyglot es un plugin para WordPress que te permite escribir las entradas en varios idiomas y dar la oportunidad al usuario de leerlo en uno u otro idioma. Tu tienes que escribir la entrada en los dos idiomas y cada una entre unas etiquetas específicas que explicaré más adelante. […]

  229. » Polyglot 23. 11. 2005 / 3.25

    […] Ja esta funcionant com volia el plugin per wordpress Polyglot, el traductor manual. Aquest plugin esta basat en el que feia servir abans jo, el Language Picker. Les millores que te es que detecta els tags en els post’s i si no escrius en un idioma no et possara la disponibilitat d’aquest. […]

  230. Denis 23. 11. 2005 / 19.36

    Thanks for the plugin.
    Please add ‘he’ (for Hebrew) to knownlangs array in get_users_pref_lang() function (line 408). Without it, even if user has set her default lang to ‘he’, it has no effect by default.

    An additional question: does anyone has an idea how to switch stylesheets based on the chosen language? For Hebrew and Arabic, it is a necessity, as one needs to set the correct reading order for various elements (ltr, rtl).

    Thank you, Denis.

  231. malyfred 23. 11. 2005 / 23.48

    Denis> Thank you. I’ve added ‘he’ to the list of recognised languages.

    I think that comment #133+134 could help you with ltr and rtl.

  232. » I tu, quins plugins tens?Y tu, ¿que plugins tienes? 25. 11. 2005 / 1.58

    […] – Polyglot: El plugin per traduir, ja comentat […]

  233. martin 25. 11. 2005 / 15.29

    Hi,I am trying to install this useful plugin but it seems i am kinda stucked with my work. I have 3 languages to chose on my web . Translation of works fine but category list contains numbers of posts made in category under different language so menu looks really messy. Any suggestions?

  234. martin 25. 11. 2005 / 15.32

    ….and actually i noticed that posts have the same problem: text of post is not shown but other information such a date of post, name are still presented:(

  235. malyfred 26. 11. 2005 / 2.12

    martin> I’ve checked your page and it seems fine. Only the post content has just one language version.

  236. martin 26. 11. 2005 / 10.25

    malyfred::. the problem is that in the sidebar, under catigories I have translated items with __ and after switching language to other one, they still have tracks in menu (they are still presented somehow: number of posts in translated category what does not belong to switched language). It seems 2 b filtering problem…..but I can not force code make right job:(

  237. Polyglot for B2Evolution 26. 11. 2005 / 12.20

    Polyglot for B2Evolution

    Polyglot is a plugin for B2Evolution blogging system.

    It allows one to write multiple language version of the same post. It utilizes a set of tags in form <lang locale=”en”></lang>.

    Polyglot for B2Evolution has its roots in plugin w…

  238. malyfred 26. 11. 2005 / 13.32

    martin> When you use gettext (= __ function) you have to have all translations in appropriate .mo files.

    Try the second method wiht <lang_xx> tags.

  239. martin 26. 11. 2005 / 19.48

    hm…ok, I will try to explain again: I made two posts on my site- one in russian and the other one in estonian including lang_xx tags. Now when I’m switching on estonian language I c the post in estonian aaaaand the name of post in russian insead of my desire displaying only content of estonian page…

  240. martin 26. 11. 2005 / 21.16

    malyfred::. do not bother urself with answer….solved my problem:) thnx 4 nice plugin;)

  241. schilke 29. 11. 2005 / 17.03

    thx for that useful plugin. Just wanted to post a small note on an issue I would probably loose out of sight:
    Line 18 of your code
    “$polyglot_settings[‘trans’][‘de’] = ‘deutch’;”
    better should read
    “$polyglot_settings[‘trans’][‘de’] = ‘deutsch’;”
    I haven’t finnished work with my implementation yet but I will let you know when.

  242. malyfred 29. 11. 2005 / 18.14

    schilke> Danke schön! Ich spreche Deutsch sehr schlecht:(

  243. MFA 29. 11. 2005 / 22.14

    Malyfred, thank you so much for making this plugin – it’s great and much appreciated!

    I have implemented in on my (first ever!) website with a bit of hacking and slashing here and there. There is just one little problem left. I cannot get “it” to remember the language setting for my front page.

    My website structure is like this:

    (root)
    wordpress/ (normal wordpress dir)
    index.php

  244. MFA 29. 11. 2005 / 22.15

    (my last comment was cut off) here’s the rest:

    (root)
    wordpress/ (normal wordpress dir)
    index.php

  245. MFA 29. 11. 2005 / 22.16

    (sorry for spaming your comments :-( :-( )

    (root)
    wordpress/ (normal wordpress dir)
    index.php — my own front page

    in my index.php i just call lang_picker_repect_more() on the text that I want translated.

    I have nailed the problem down to that $lp_lang_pref is empty in my front page. Could you please provide me with a hint on how to solve this problem?

    The site is not online yet so unfortunately I can’t provide you with a link.

    Thanks in advance!

  246. malyfred 30. 11. 2005 / 1.27

    MFA: Do you use “polyglot_list_langs” function? Do you have all languages in “$polyglot_settings[‘knownlangs’]”?

  247. MFA 30. 11. 2005 / 22.11

    Malyfred;
    Yes I use polyglot_list_langs(true) to show flags. Also the $polyglot_settings[‘knownlangs’ are set up correctly. Everything works: Blog, pages, categories, titles etc., they are all translated correctly and every page “remembers” what language I choose when pressing a flag – Except: Everytime I go to host/index.php I get the default language and $lp_lang_pref is 0

  248. malyfred 1. 12. 2005 / 1.53

    MFA> Does it work for you on my page? When you change the language in the sidebar and then return to the main page?

    Because the selection in the menu means that the language code xx (lp_lang_pref=xx) is saved in cookie and all pages should be translated into that language then. Your problem could be in the configuration of your browser.

  249. MFA 1. 12. 2005 / 19.42

    Malyfred,
    Yes your site works fine – but your site is also different from mine in the way that your front page is part of the wordpress “package” – mine is not.
    mine:
    wwwroot/
    index.php — my special front page
    wordpress/
    wordpress/index.php — wordpress front page with blog
    wordpress/wp.php
    etc.

    Maybe it’s because that my index.php front page do not access the cookie data? I tried to copy your cookie code from polyglot.php (line 93-102) into my index.php but that didn’t help.
    I don’t know too much about PHP (even if I have a programming background) maybe I should just get into it :-)
    I’ll try to get my site online soon – would probably make it much easier.

    I really appreciate that your are taking time out to help me like this. Thanks.

  250. malyfred 1. 12. 2005 / 23.55

    MFA> You should be able to get what you need when you call “polyglot_get_lang()”

  251. Akela 2. 12. 2005 / 15.54

    Thanks for Plugin!
    I’ve read about translate-categories.php plugin in comments, but have problem locating it.

  252. malyfred 2. 12. 2005 / 22.51

    Akela> translate-categories plugin does’n exist anymore because it was implemented in Polyglot.php (this is mentioned in “Fixes”). “How to translate categories” is described in the post.

  253. Akela 3. 12. 2005 / 9.40

    Malyfred> Thanks for clearing this.
    May i ask more : echoing category title (in archive.php )results in string:
    русскийenglish

    wp_list_cats() is translated correctly. All other content (so far) also. Did i miss something?
    Thanks in advance!

  254. malyfred 3. 12. 2005 / 12.36

    Akela> I guess you use “single_cat_title()” function for displying category’s name and WP doesn’t have any hook for this function. Polyglot cannot filter the title automatically here:( It’s a bug in WP.

  255. Akela 3. 12. 2005 / 21.04

    Thanks , I was ready to die in front of my computer trying to solve the issue….
    Btw, thanks for Iimage-gallery !

  256. TyskJohan's random thoughts 6. 12. 2005 / 17.06

    En flerspråkig blogg, ja…

    Det kan ju verka lite pretentiöst att skriva på flera språk i en och samma blogg. Samtidigt är det ganska naturligt för mig, framför allt när jag skriver om saker som har väldig mycket med ett land (och därmed språk) att göra – och väldigt…

  257. Jamal Abdou Karim Bengeloun 8. 12. 2005 / 0.01

    Thanks a lot for this great plugin.
    I have just started playing with it. You should clarify the part when you say : “they should be renamed to xx.mo” – I tried that renaming it to say fr.mo (two letters), but in fact one should leave it at fr_FR.mo otherwise you get an error.

  258. malyfred 8. 12. 2005 / 3.10

    Jamal> NO, you have to rename it to ‘fr.mo’. I guess you should read “known issues” again and set:

    define('WPLANG', 'fr')

    and not ‘fr_FR’. Also all ‘knownlangs’ must be ISO codes – two letters again.

  259. martin 8. 12. 2005 / 13.50

    Malifred>here is my site where i’m tryng and trying to put Ur plugin…everything works fine except switching between langugaes ‘coz it switches only for a main page and goes back to default every time when i wander trough menu:( and it seems not to be coockies problem

  260. martin 8. 12. 2005 / 13.52

    forgot to add url http://martinos.glwb.info/

  261. malyfred 9. 12. 2005 / 0.33

    martin> That’s because you use lp_lang_view instead of lp_lang_pref. “view” is for individual post and doesn’t save anything to the cookie. Recomended is using “polyglot_list_langs” function as is mentioned in the post.

  262. martin 9. 12. 2005 / 9.14

    ok i’ve added polyglot_list_langs string to my sidebar code but the problem still presists: i can change language for particular post or page but not for whole site even using lp_lang_pref….

  263. martin 9. 12. 2005 / 10.22

    dunno how but i solved my problem again:)

  264. Mort 9. 12. 2005 / 23.30

    After hours of head-scratching, I discovered (in one of the comments above) that you must edit the wp-config.php file before copying the .mo files into the languages directory.

    You must change:

    define (‘WPLANG’, ”);

    to:

    define (‘WPLANG’, ‘en_US’);

    Otherwise you will get the following error:

    Fatal error: Cannot instantiate non-existent class: cachedfilereader in /wp-includes/wp-l10n.php on line 72

    I think it would be great if you could explain a little more about installing .mo files in the main article above.

    Thanks very much for the plugin!
    Mort

  265. malyfred 9. 12. 2005 / 23.38

    Mort> If you had read “known issues” in the post properly you would have known this fact from the very beginning…

    And btw it should be
    define (’WPLANG’, ‘en’)
    as is described in the post as well. Otherwise the automatic language detection doesn’t work.

  266. Mort 11. 12. 2005 / 0.15

    Thanks again malyfred! Sorry I missed that! I have another question though.

    Is it possible to translate the titles of the Link Categories into multiple languages? I tried putting the title strings into my .mo files, but that had no effect, and i also put the tags into the titles, but they just show up in the rendered pages.

  267. malyfred 11. 12. 2005 / 4.27

    Mort> Bad news is that you cannot translate link names with Polyglot because WP doesn’t have any hook that could be used for it… sorry:(

  268. Michael 13. 12. 2005 / 10.56

    Hi malyfred

    Thank you very much for a great plugin :-))
    I am all smiles, since that is exactly what I was looking for.

    I have compiled the install information in a small textfile and I will email it to you; maybe you can post it for newbies…

  269. alle 13. 12. 2005 / 12.32

    Hi malyfred,
    I’ve the same problem as martin
    had in comment #259.
    I use polyglot_list_langs in sidebar, but the issue persists.
    I have not been able to solve it out (as martin did). :(

  270. malyfred 13. 12. 2005 / 12.40

    alle:: And everything works fine on my site? Also link would be nice so I could test it on my own.

  271. alle 13. 12. 2005 / 12.49

    It seem working all right on your site. I’ve no address, since I’m working on a local server.
    Here it seems that the “$posts[0]->ID;” element in polyglot_list_langs function is empty.

  272. malyfred 13. 12. 2005 / 13.38

    alle:: Don’t care about that value it’s just little workaround to allow changing language even when user is browsing deeper in the web structure without redirecting him to the front page. The only important parameter is “lp_lang_pref=xx” where xx is the ISO code that should be saved to a cookie then.

  273. alle 13. 12. 2005 / 14.04

    malyfred> OK, setting are all OK. The cookie is set. The browser is properly configured for the base language selection. The URL generated by your functions report the right parameter for the language selection but it is “truncated” at the end, it does not containt the proper page_id parameter. So it always goes to the site’s main page. :(

  274. Hiddenson 13. 12. 2005 / 14.32

    Hi,

    While I see the use of your plugin, I fail to see the difference between Polyglot and Language Picker. Both seem to do the same thing, am I correct?

    Thanks for pointing out any distinctions I may have missed.

  275. malyfred 13. 12. 2005 / 15.50

    Hiddenson> Have you read the post at all? This IS completely based on Language Picker but I’ve fixed many bugs and added support for translating categories and automatic detection of visitor’s prefered language and lot of other stuff. LP doesn’t seem to be maintained anymore:(

  276. malyfred 13. 12. 2005 / 15.57

    alle:: I wouldn’t be worried about it as this function is mainly for selecting prefered language and if you want to switch the language of particular post you should use “lp_other_langs”. I have played around with the ID parameter in last two months quite a lot but I’ve failed as there is no “bullet proof” way how to get the ID:( Try to insert sidebar.php to the single.php (and others) after the WP loop. It could help.

  277. Hiddenson 13. 12. 2005 / 16.39

    Malyfred,

    It was a misunderstanding, no need to get picky here! I read your post as well as Language Picker, but I was not sure whether your plugin would work as standalone or if it needed Language Picker preinstalled. “Based on…” could mean anything, a credit to an author or a requirement.

    That being said, I finished the implementation of your plugin and it’s working perfectly, so thank you very much for your work and for releasing this to the community :)

  278. malyfred 13. 12. 2005 / 16.53

    Hiddenson:: ok, ok:) I’m just anwsering to too many questions and should be a bit more patient I guess.

    But good to know that this plugin helps to other people.

  279. Wordpress mehrsprachig (Schröttle’s Krimskrams…) 13. 12. 2005 / 20.50

    […] Seit heute ist mein WordPress zweisprachig Nicht das das jetzt heisst, dass alle Posts automatisch in Deutsch und Englisch erscheinen werden – das hängt ganz von meiner Laune ab… Die Möglichkeit danke ich fred und seinem fabelhaften Plugin ‘polyglot’ – zu finden unter ‘WordPress polyglot’ im Google oder direkt: http://fredfred.net/skriker/index.php/polyglot; die Anleitung ist nicht ganz so einfach zu durchschauen, aber nach drei Stunden war klar wie es läuft und wie es mit dem Template usw. zusammenspielt; und so nebenbei hab ich auch noch gelernt, wie WordPress die lokalisierung macht.   [link] […]

  280. hlb’s weblog » Multilingual Blogging 15. 12. 2005 / 2.52

    […] 查找一番後,知道我目前用的WordPress系統有這些選擇,就決定在自己筆記型電腦試試看(我在iBook裡跑了個測試用的http://hlb.yichi.dev/)。結果發現堪用的只有polyglot。Multilingual雖然看起來比較完整,連管理介面都做了,可是裝起來實在問題一堆,不知道從何改起。如果最近有時間,就會開始好好玩polyglot吧。 […]

  281. Hiddenson 15. 12. 2005 / 7.07

    Hello again,

    As per comment #267, does this mean there is no other solution for translation of link names than hard coding them in the template? Ugly, I know, but it could be ok if there were links added rarely, if ever.

    Right now, I use get_links(), and I don’t see another solution than the one above… What do you think?

  282. malyfred 15. 12. 2005 / 13.38

    Hiddenson:: Well, you could write your own function for printing link list (just copy and paste get_links() code with calling Polyglot inside).

    I’ll do that one day if there will be still no hook for links in WP 2.0.

  283. TyskJohan’s random thoughts » Blog Archive » Fiddling with the blog 16. 12. 2005 / 18.57

    […] I might give the other contestant, polyglot, a whirl also. […]

  284. yuri vieira 16. 12. 2005 / 23.53

    Hi malyfred
    This is a great plugin. But – like the others – I have a problem. My language is brazilian portuguese “pt_BR”, but when a set that value in polyglot.php I got an error. When I put only “pt”, my post disapear, and rest only the flags (spanish and portuguese). I have tried to change the wp-config and the pt_BR.mo to “pt” but doesn’t work. What I need to do? Thank you so much.
    Yuri

  285. malyfred 17. 12. 2005 / 0.09

    yuri vieira:: Set “pt” everywhere, rename the file to pt.mo and use <lang_pt> in the post. Everything will be fine.

  286. yuri vieira 17. 12. 2005 / 0.31

    Thank you, malyfred. I will try. :)
    {}’s

  287. gleamynode.net » Blog Archive » 유용한 WordPress 플러그인들 17. 12. 2005 / 20.33

    […] Polyglot – 다국어 블로그 운영의 필수품. (URL Rewrite 에 약간의 버그가 있어 소스를 수정해야 했습니다.) […]

  288. Anleitung: Wordpress für Internet Marketer (Schröttle’s Krimskrams…) 27. 12. 2005 / 1.39

    […] 9. Polyglot: Macht WordPress zum Mehrsprachigen CMS mit Hilfe einfacher Tags, die in den Posts verwendet werden… […]

  289. Michael 27. 12. 2005 / 14.56

    Hi Fred
    Polyglot gives a link for the translate flag of an item that reads like this: /?p=&lp_lang_view=
    Can this be changed so that the permalink for the chosen language is returned, i.e. //
    Same goes for the function that switches between language preferences for the site:
    instead of /?lp_lang_pref=xx&p= just render / and process the parameters in the background???
    thank you very much for your feedback.
    Michael

  290. malyfred 28. 12. 2005 / 14.41

    Michael:: Well, I have done a lot of work about this but WP 1.5 is a bit buggy when it comes to permalinks. You can achieve this behaviour manually if you understand .htaccess file. Let’s hope that WordPress 2.0 works better.

  291. Marc 1. 1. 2006 / 22.03

    2.0 stable is out! :-) There is a hook now to also translate pages, isn’t there?

    Marc

  292. TyskJohan 2. 1. 2006 / 10.32

    Hey!

    Will there be an update to 2.0? The permalink hack at least doesn’t work any more…

  293. TyskJohan’s random thoughts » Blog Archive » WordPress 2 2. 1. 2006 / 15.45

    […] Not much changed on the surface, but quite a lot below said surface. For instance, parts of the Polyglot plugin seems to have quit working. […]

  294. Sjors 3. 1. 2006 / 13.56

    The problem that i found is that in the normal text editing mode i can’t use the tag anymore because the texteditor they use only supports known html tags.. the hack could probably be in suporting the lang-tag, but i wasnt able to find out where.. anyone any idea?

  295. Yannick Lefebvre 4. 1. 2006 / 2.57

    I switched to the plain text editor to be able to use Polyglot correctly in WordPress 2.0. However, even with this done, I am still having problems with language tags used in the post title.

    I was using language tags in the title so that people would see a post’s title in their selected language. However, now, I just get an error about badly formed XML in the page with these tags in the post title. It would be very good to get this correctly as well.

    I have posted this additional incompatibility on the WordPress Codex.

  296. Alex Kessaris 4. 1. 2006 / 9.01

    I think that the polyglot plugin has excellent potential. I have noticed however that the syntax

    does not always work because of the capitalization of the letters in the link.

    additionally, I would like to know what would be the best way to get the address of the current page in the event that it is not a blog entry?

    For instance a contact page.. supposing the

    URI is http://www.domain.ca/contact

    the links of pages become cut off:

    http://www.domain.ca/?lp_lang_pref=pt&page_id=

    which causes the site to return to the home page. This is an annoyance more than a bug.. but is there a way that the current page can be accessed in the event that it is not a blog entry? for instance using a permalink? What I’m trying to say is.. is it possible that the polyglot behaviour can extend to pages as well as blog entries?

  297. Alex Kessaris 4. 1. 2006 / 9.05

    sorry my uri’s got cut off.. the first one is

    www.domain.ca/contact

    and then the polyglot links on the page do not retain the link to the contact page, but rather appear as follows:

    http://www.domain.ca/?lp_lang_pref=pt&page_id=

    which returns to the main page rather than the contact page. Is there a way to get the current page and use it in the polyglot links? Thank you.. sorry for the double comment!

  298. Alex Kessaris 4. 1. 2006 / 9.06

    A follows

    http://www.domain.ca/?lp_lang_pref=pt&page_id=

  299. Alex Kessaris 4. 1. 2006 / 9.08

    oh cripes! somebody delete these I am so sorry! how embarassing! like this:

    www.domain.ca/?lp_lang_pref=pt&page_id=

    when it should be:

    www.domain.ca/contact/?lp_lang_pref=pt

    Thank you! sorry!

  300. malyfred 4. 1. 2006 / 15.42

    Marc:: What do you mean by “translate pages”? You can translate pages and their titles in exactly same way as post since 22.9.2005

  301. malyfred 4. 1. 2006 / 15.45

    TyskJohan:: I hope that WP developers have rewritten the whole permalinks part (it was quite buggy) and I’ll have a chance to implement it properly. Give me some time to find out what’s new.

  302. malyfred 4. 1. 2006 / 15.46

    Sjors:: I’ll fix this soon and you’ll be able to use in WYSIWYG.

  303. malyfred 4. 1. 2006 / 15.51

    Yannick Lefebvre:: What exactly doesn’t work for you? Here http://fredfred.net/wp/ is my testing blog and everything works fine…

  304. malyfred 4. 1. 2006 / 16.11

    Alex Kessaris:: Fixed, download the latest version. It doesn’t keep the permalink structure yet, but I am working on it.

  305. Alex Kessaris 4. 1. 2006 / 21.36

    Hello again!@
    There is such a function in wordpress called get_permalink() that seems to work quite effectively. It would be good to like check if we are outside the blog chronology (ie in a page) and then use this function I think..

    Thank you for all your effort! this is gonna be great.. but we must also thank the author of language picker I feel.

  306. Alex Kessaris 4. 1. 2006 / 21.45

    You’re right. it’s still buggy. Sorry for all the multiple posts! There must be a good way to track the current url though!

  307. Marc 5. 1. 2006 / 0.07

    malyfred: It meant to say “page menu entries”, sorry. :-)

  308. malyfred 5. 1. 2006 / 1.28

    Marc:: well, I still don’t understand what’s the problem:( It works with “wp_list_pages” function.

  309. Enno 5. 1. 2006 / 14.52

    Hello malyfred,

    first of all, “A happy new year!” and thanks for devellopping this great plugin.

    However, polyglot seems not to work with permalinks.
    If I enter into title e.g.
    EinsOne
    I see “Eins” or “One” for the post title depending the choosen language.
    But the permalink is “einsone”.
    Is there any possibility to show “eins” for the German version and “one” for the English (better for search engines)?
    That would be great!

    Thanks in advance & have a nice day.

  310. Enno 5. 1. 2006 / 14.56

    Sorry, it’s me again, it has to be:
    If I enter into title e.g.
    <lang_de>Eins</lang_de>
    <lang_en>One</lang_en>

  311. malyfred 5. 1. 2006 / 15.16

    Enno:: That’d be nice but as far as I know this is not possible in WP. There’s still a lot of work about permalinks and Polyglot waiting for me so maybe I’ll find some workaround.

  312. TyskJohan 6. 1. 2006 / 14.52

    Regarding Enno’s point. The Redirect Old Slugs plugin may give you a pointer as to how this could probably be done.

  313. Jobo 6. 1. 2006 / 18.06

    I’ve read all the reactions here. But I’ve tried to do everything, but I always get this error:

    Warning: Cannot modify header information – headers already sent by (output started at /local/web/websites/1672429154/www/web/index.php:2) in /local/web/websites/1672429154/www/web/wp-content/plugins/polyglot.php on line 95

    Help! What’s the reason?

  314. malyfred 6. 1. 2006 / 21.17

    Jobo:: Do you get the same error even when you use unmodified polyglot.php?

  315. nemo 7. 1. 2006 / 0.13

    Hi Malyfred,
    I’m using Polyglot and Character Map and they work like a charm on my blog! Thanks for the great plugins!
    I couldn’t figure out yet a solution to make bilingual RSS work with redirected feedburner, but I’m working on it.
    Keep up the good work!

  316. malyfred 7. 1. 2006 / 1.35

    nemo:: Thank you! and if you found the way how to pass some parameters through the Feedburner – let us know. I am using two separate feeds on Feedburner for that purpose at the moment.

  317. Enno 7. 1. 2006 / 21.38

    malyfred, I had a look at plugin of #312. It could be useful, … but you know better your code. ;-)
    Till then two other questions please:

    1) I like to use polyglot for comments too.
    Therefor I have to allow the HTML-tag <lan_xx> into comments.
    [xx has of course to be replaced by the needed language]

    Easy to find, I have to add
    ‘lan_xx’ => array ()
    into “$allowedposttags” in wp-includes/kses.php

    [ Would be nice if you add it too ;-) ]

    Now a visitor can add multilingual comments, … BUT …
    … how do I show his comment?
    If I want to replace a simple text like “good evening”, I write
    _e(‘good evening’)
    and translations will be searched in “.mo” files.

    But here, content will be showed by
    comment_text()
    It’s impossible to write
    _e(comment_text())

    So what do I have to do???

    2) The same problem for other functions. How do I use gettext for them?

    Thank you so much.

    BTW: Did you change your .css file? Your bakground is nearly black now and the grey font is difficult to read.
    If I adjust more brightness for your page, my monitor is too clear for all other pages.

  318. Enno 7. 1. 2006 / 21.58

    Oups, I forgot to ask how to show dates in different formats.
    Is there another possibility than using the following code that I wrote for index.php?
    Can I use polyglot for
    the_time()
    or
    the_date() ???

    <?php
    $lan = polyglot_get_lang();
    if ($lan==”fr”) {
    $time = “d/m/Y”;
    }
    if ($lan==”de”) {
    $time = “d.m.Y”;
    }
    if ($lan==”en”) {
    $time = “Y-m-d”;
    }
    ?>
    <small><?php the_time(‘l, ‘.$time.’ | H:i:s’); echo ” (“; the_author(); echo “)”; ?></small>

  319. malyfred 8. 1. 2006 / 1.03

    Enno:: At first, look at http://fredfred.net/skriker/index.php/monitor-calibration/ and then try “look&feel” section in the menu.

    Back to the Polyglot.

    ad comments)
    Re-download the latest version and your visitors can write comments in different languages immediately using:
    [lang_xx] bla bla [/lang_xx]

    test – next paragraph is either in czech or english – according to your language selection:

    český text

    ad time)
    I have added new functions related to the time and date. Basically – just set the time and date formats for each language.

  320. Enno 8. 1. 2006 / 19.33

    malyfred,

    thanks again for you quick help, that’s great!

    1) I changed to "Pale Skriker". ;-)

    2) All is OK with polyglot and comments, cool!

    3) I set time and date formats, but your functions don’t work. So, I wrote another one that’s even more flexible. What do you think of replacing yours? Here comes the code:


    function polyglot_datetime($l='l', $d='', $pc=''){
      global $post,$comment,$lp_lang_pref,$polyglot_settings;

      if ( $l=='l' ) {
        $l = "l, ";
      } else {
        $l = "";
      }

      if ( $d=='' ) {
        $d = $l.$polyglot_settings['date_format'][$lp_lang_pref]." ".$polyglot_settings['time_format'][$lp_lang_pref];
      } else {
        $d = get_settings('date_format');
      }

      switch ($pc) {
      case 'post_date':
        $pc = $post->post_date;
        break;
      case 'post_modified':
        $pc = $post->post_modified;
        break;
      case 'comment_date':
        $pc = $comment->comment_date;
        break;
      default:
        $pc = date("Y-m-d H:i:s",time());
        break;
      }

      $the_date = mysql2date($d, $pc);
      echo $the_date;
    }

    4) Sorry, but I found a little bug. If you show a limited number of posts in "index.php", you’re on page 2 or 3 or … and you change language by global flags (function "polyglot_list_langs"), you’ll go back to homepage (page 1).

    5) How can I use Polyglot for Blogroll and other plugins like Recent Comments (http://blog.jodies.de/archiv/2004/11/13/recent-comments/)?

    6) Are there already news about polyglot and permalinks (#309, #312)? Please inform us…

  321. malyfred 8. 1. 2006 / 20.06

    Enno:: the_date(), the_time() and comment date and time functions definitely work – you can see it on this web. Don’t forget that if you pass formating parameter to any of these functions – it’s superior to the Polyglot settings.

    I prefer using standard functions and changing their results through the hooks.

    4)Fixed

    5) Comment #4

    6) Using custom fields doesn’t sound good for me at the moment. You can use above mentioned plugin if you want but I’d prefer some nicer way.

    I have complete solution for generating permalinks (instead of lp_lang_view etc.) and adding all necessary rules for them but it doesn’t work at the moment with “index.php” in it, because of some WP security limits. You can use permalinks with .htaccess file if you set it manually.

  322. Enno 8. 1. 2006 / 23.49

    Hello malyfred, you’re really helpful, thank you so much!

    3) The functions definitely work. It was my mistake, sorry.

    > I prefer using standard functions and changing their results through the hooks.
    You’re right. But how do you show
    a) date & time of “post_modified”
    b) actual date
    ???
    You have to add other functions “post_modified” and “actual_date”, isn’t it?

    4) Super, thanks!

    5) Sorry, I really don’t understand how to do. :-(

    In order to test, I have filled “Link Name” and “Short description” of a new link with
    en

    These link is called in the sidebar by
    get_links_list()

    So, I want to obtain in my blogroll
    fr if French is choosen,
    de if German is choosen and
    en if English is choosen.

    But I get
    en

    Comment #4 doesn’t help me because I don’t know how to use the function.
    No result if I put
    lang_picker_respect_more(get_links_list())
    in my sidebar or if I add to polyglot.php
    add_filter(‘get_links_list’, ‘lang_picker_respect_more’,1);

    Please help me.

    6)
    > but I’d prefer some nicer way.
    What’s your way? Adding all necessary rules to .htaccess?
    I don’t understand what to do to solve my problem of #309.
    Is it enough to set in polyglot.php
    $polyglot_settings[‘lang_rewrite’] = true;
    and to add to .htaccess the lines
    RewriteRule ^(.*)/de/?$ /$1?lp_lang_view=de [QSA]
    RewriteRule ^(.*)/en/?$ /$1?lp_lang_view=en [QSA]

    Would you please give my detailed steps or could you tell me where to find a description?!
    Or could you explain exactely your way?

  323. Enno 8. 1. 2006 / 23.59

    Sorry, replace (of course without spaces before and after lan_xx):

    In order to test, I have filled “Link Name” and “Short description” of a new link with
    en
    == BY ==
    [ lang_fr ]fr[ /lang_fr ][ lang_de ]de[ /lang_de ][ lang_en ]en[ /lang_en ]

    AND

    But I get
    en
    == BY ==
    [ lang_fr ]fr[ /lang_fr ][ lang_de ]de[ /lang_de ][ lang_en ]en[ /lang_en ]

  324. malyfred 9. 1. 2006 / 2.11

    enno::

    ad 3) Ok, ok – here is your function:
    polyglot_time($d = '', $time = '')

    First parameter is optional formating string and second is time either as an unix timestamp or WP’s timestamp (like $post->post_date etc.)

    example:
    echo polyglot_time('', time() );

    ad 5) ahhhh – step by step:
    1] visit http://codex.wordpress.org/Template_Tags/get_links

    2]
    echo lang_picker_respect_more( get_links(blabla...,false) );

    ad 6) I’ve found workaround (still doesn’t work with pages:( for permalinks using “index.php” you can test it now. Just set “lang_rewrite” to true.

    If you don’t want to have “index.php” in your permalink structure you have to find proper rules that you have to add to the .htaccess. Continue: http://www.google.com/search?client=opera&rls=en&q=mod_rewrite+rules&sourceid=opera&num=50&ie=utf-8&oe=utf-8

  325. Jobo 9. 1. 2006 / 10.51

    Malyfred: a reaction on your question no. 314:

    yes, the same error….:(

  326. Jobo 9. 1. 2006 / 11.30

    I see that the error is:

    if ($_GET[“lp_lang_pref”]) {
    setcookie($polyglot_settings[‘lang_pref_cookie’], $_GET[“lp_lang_pref”], time() + 30000000, COOKIEPATH);
    $lp_lang_pref=$_GET[“lp_lang_pref”];
    }

    But why??

  327. malyfred 9. 1. 2006 / 12.44

    Jobo:: Download the latest version of Polyglot and install it. Then turn all other plugins off and you’ll see. If it works, turn other plugins on one by one until you find witch one is the problematic one.

  328. Sjors 9. 1. 2006 / 17.05

    hey thanks for making an update so fast :) i will try it tomorrow

  329. Jobo 9. 1. 2006 / 17.43

    Thanks Malyfred.
    It works.

    Only de titles on the pages doesn’t translate.

  330. malyfred 9. 1. 2006 / 17.53

    jobo:: Comment #203 or use [] tags

  331. Enno 10. 1. 2006 / 1.49

    3) Thank you very much, you’re great!
    I propose a little modification in order to allow choice of output format: only date, only time or both.
    By calling function on pages, you even don’t need third parameter, i.e. e.g. for output of date and time of modified post:
    <?php echo polyglot_time(”, $post->post_modified); ?>

    Here comes my code. Feel free to put it into the next version:

    function polyglot_time($d = ”, $time = ”, $dt = ”) {
      global $lp_lang_pref,$polyglot_settings;

      switch ($dt) {
      case ‘d’:
        $dt = $polyglot_settings[‘date_format’][$lp_lang_pref];
        break;
      case ‘t’:
        $dt = $polyglot_settings[‘time_format’][$lp_lang_pref];
        break;
      case ‘dt’:
        $dt = $polyglot_settings[‘date_format’][$lp_lang_pref]." ".$polyglot_settings[‘time_format’][$lp_lang_pref];
        break;
      default:
        $dt = $polyglot_settings[‘date_format’][$lp_lang_pref]." ".$polyglot_settings[‘time_format’][$lp_lang_pref];
        break;
      }

      if($d == ” && isset($polyglot_settings[‘time_format’][$lp_lang_pref]) && isset($polyglot_settings[‘date_format’][$lp_lang_pref])){
        $d = $dt;
      }

      if(strpos($time, ‘-‘)){//trick to find you if we’ve got "mysql time" or unix timestamp
        $time = mysql2date($d, $time);
      }
    else {
        $time = date($d,$time);
      }

      return $time;
    }

    5) Thank you again for your effort and patience! That works fine.
    But there remains a problem (#317,2 and #320,5) that seems to me the same as Jobo’s: How do you apply Polyglot to general functions?
    Take for example Jobo’s problem that title is not translated. In "archive.php",
    <?php echo single_cat_title(); ?>
    displays original code with [ ] tags.
    Do we have to use your function "lang_picker_respect_more" and how to do so?

    6) Thanks, I’ll try later, have no more time today.

    7) NEW:
    When I’m in archives, e.g. "2006/01/01/" and want to change global language, I turn back to homepage.
    Perhaps same fix to use as for #3210, 4) ?!

    8) NEW:
    Last but not least [and perhaps even not last… ;-)] a little question:
    I handle three languages (fr, de, en). If I enter only one or two of these languages in my posts and change global language to non-existing one, I’ll see no content.
    Is there any possibility to show a standard text for absent language?

  332. malyfred 10. 1. 2006 / 3.53

    enno::
    ad 3) Download the latest version – there is “polyglot_date” that allows you to combine results as you want.

    ad 5)
    echo lang_picker_respect_more( single_cat_title() );

    Just pass the text to the fucntion and you get proper language version back.

    ad 7) and also in many other cases (author, archive of any kind, categories…) you should get used to it. Don’t forget that Polyglot is still using “workaround” and is not actually really implemented into WP permalink system. That’s because of limitations of WP at the moment. That means that not all “issues” can be solved. Of course they can be, but then the code is getting too complicated and any future developement will be much slower due to too many “workarounds” inside. Let’s hope I’ll find some nice solution one day.

    ad 8) if default language version is present then it’s used. If not – no content, that’s the feature not bug. Switch to swedish on this web to see this feature in action.

  333. Jobo 10. 1. 2006 / 10.30

    Thanks for your reaction Malyfred.
    But I’ve read comment #203 but it’s no solutions for me…:(

    An other idea maybe?

  334. malyfred 10. 1. 2006 / 13.25

    jobo:: as I said – use: [lang_xx] instead of <lang_xx>

  335. Enno 11. 1. 2006 / 0.48

    First, I really like to compliment you on your quick reaction and work.
    Thanks a lot!

    3) OK, your short function is better. Thanks, it works.

    5) I use as test category name (of course without spaces after [ and
    before ]) the following
    [ lang_fr ]fr[ /lang_fr ][ lang_de ]de[ /lang_de ][ lang_en ]en[ /lang_en ]

    After having modified in archive.php
    <?php echo single_cat_title(); ?>
    to
    <?php echo lang_picker_respect_more(single_cat_title()); ?>
    I always get
    [ lang_fr ]fr[ /lang_fr ][ lang_de ]de[ /lang_de ][ lang_en ]en[ /lang_en ]
    instead of "fr", "de" or "en".

    I think, it’s jobo’s problem, too. What happens and how to fix?

    7) OK, so let’s wait and see… ;-)
    In the meantime I tried something. I replaced in your function "polyglot_list_langs" line
    <?echo get_settings('siteurl')."/?lp_lang_pref={$value}"; ?>
    by
    <?echo $_SERVER['REQUEST_URI']."/?lp_lang_pref={$value}"; ?>

    It works fine for all cases (author, archive of any kind, categories…)
    but one:
    If you just changed language, you’ll get your
    URI plus "/?lp_lang_pref=xx&p=y". So if you change directly to another language you’ll get
    URI plus /?lp_lang_pref=xx&p=y" plus "/?lp_lang_pref=xx&p=y".
    Perhaps you can fix it by using preg_replace() ?!

    8) I see and understand that’s a feature. You’re right.
    But it only works if I entered text in default language.
    I wonder if there’s a possibility to show a standard text if the default language version doesn’t exist.

  336. malyfred 11. 1. 2006 / 1.20

    Enno::
    ad 5) http://codex.wordpress.org/Template_Tags/single_cat_title

    and you should consider using Codex more often.

    ad 7) Yes, it works but I am looking for complete “permalink only” solution. First signs can be seen on this page. Look at the language offer in the menu.

    ad 8) What do you mean as a “stadard text”?

  337. Enno 11. 1. 2006 / 1.43

    ad 5) & 7) I’ll look this evening…

    ad 8) The display of e.g.
    “Sorry, article not available in this language”
    Of course for all used languages.

    CU L8er & good night.

  338. Yannick Lefebvre 11. 1. 2006 / 3.03

    Sorry for taking so long to reply. The problem only appears when I had language tags in my title and then put a link to the comment page at the end of the post. I am using permalinks which add the post title in the URLs. In this particular situation, this made an error appear in the permalinks when the tags appeared.

  339. malyfred 11. 1. 2006 / 3.56

    Yannick:: I’m sorry but I still don’t understand:( I went through all parts of you web but the only visible “problems” for me (except my “poor french”:) is that you have post slugs and page titles in both languages. Slugs were always like that – because you can manualy edit the slug when you are editing the post. Page title in both languages is old WP bug but you can fix it with using [lang_xx] instead of <lang_xx>

    You must upgrade to the latest version of Polyglot to be able to use [lang_xx].

    Maybe I don’t understand due to my poor english… I am sorry if so:(

  340. Enno 11. 1. 2006 / 23.44

    9) NEW:
    Hello, I just tested new version 0.97 with settings:

    $polyglot_settings[‘lang_rewrite’] = false;
    $polyglot_settings[‘i_have_manually_edited_my_htaccess_file’] = false;

    Unfortunately, there are some bugs:
    – homepage
    On choosing global language "?lp_lang_pref=fr" is used and works well. But if you select directely another language, "&lp_lang_pref=fr"will be used and produces an error 404.

    – archives
    Nearly same error (? first use, & second use) but language doesn’t change immediately, you have to click the flag a second time.

    5)
    > you should consider using Codex more often
    Sorry, I’ll try so. Thanks for helping. By using
    <?php echo lang_picker_respect_more(single_cat_title('', false)); ?>
    it works, category name is now translated!

    7)
    Hmm, I think you tried to use it, but there are still bugs, see 9).

    8)
    Please let me know if you find a solution.

    Good luck and good evening.

  341. malyfred 12. 1. 2006 / 1.24

    enno:: ?/& bug is fixed now. test it.

    8) implemented. test it.

  342. Enno 12. 1. 2006 / 23.24

    First of all, once again, thank you for your work.
    Please don’t understand my comments as negative criticism or push to advance.
    It’s in fact to encourage and help you.

    6)
    Are there any news concerning permalinks in different languages?
    At the moment, with settings of permalink structure without index.php but:
    /%year%/%monthnum%/%day%/%postname%.html
    and
    $polyglot_settings[’lang_rewrite’] = true;
    $polyglot_settings[’i_have_manually_edited_my_htaccess_file’] = true;

    and for each language in .htaccess
    RewriteRule ^(.*)/lang/xx/?$ /$1?lp_lang_view=xx [QSA]
    permalinks don’t change.

    But URI is changing, like on your page to "www.abc.com/lang-pref/xx/"
    By changing global language, I get an eror 404. Only by setting
    $polyglot_settings[’i_have_manually_edited_my_htaccess_file’] = false;
    it works on homepage. By choosing categories, it bugs.

    And why using "www.abc.com/lang-pref/xx/"?
    "www.abc.com/xx/" is shorter (and better for search engines) and used by international well known pages (e.g. http://www.apple.com/de/, http://www.apple.com/uk/, etc.)

    7)
    Thanks, it seems to work now.

    8)
    > implemented. test it.
    Thank you so much. Two remarks:
    a) If you want to show this "default message" (DM), you have still to enter
    [ lang_xx ][ /lang_xx ] into your article for absent language.
    Is there any possibility to show DM even if nothing is entered for absent language?

    b) If you wnat to show the DM for title too, you have to change your code from
    add_filter('the_title', 'lang_picker_respect_more',1);
    to
    add_filter('the_title', 'polyglot_filter_with_message',1);
    If you don’t, nothing will be shown in title.

    Another possibility of handling absent language version, is not to show at all the concerned article if it’s not available in global set language.
    What do you thing and is it possible to implement this, perhaps as option?

    9)
    > ?/& bug is fixed now. test it.
    Thanks, it seems to work.

  343. malyfred 13. 1. 2006 / 0.22

    enno::

    6) I cannot test it with .htaccess:( so…

    Using “lang-pref/xx/” instead of domain.com/xx/ is because second version will be confusing for rewriting rules (domain.com/postname/)

    Advanced users can help themselves anyway.

    8)
    a] I’m sure you don’t have to… Try again.
    b] I’d cosider this as a feature. Otherwise you’ll get the same message twice on the same page and there can be quite long text with explanation how to switch languages etc.

    To remove the post completely is easy but I don’t think it’s good solution because many people speak more languages and then you should let them know about other language versions of the post.

  344. Andries 13. 1. 2006 / 15.42

    Thank you malyfred for this great plugin.
    Everything works exactly like you explain in your topic.

    Now a small question for somebody on this blog :
    how can I add a line to my .po file?
    I understand the whole proces, and I have “poedit” – but now I want to add a line with my custom translation of a category. I guess I really missed something.

    Many thanks

  345. Tantra 13. 1. 2006 / 16.49

    Using Feedburner with Polyglot…

    This one is a technical post, malyfred wrote me as a reply on his Polyglot WordPress plugin blog that I should let them know if I succeed in using his plugin with Feedburner.
    Finally I had some time to think on how to implement multilingual RSS with …

  346. Wurblzap 14. 1. 2006 / 1.39

    alle:: (and possibly others) — I had a similar cookie problem and made it work for me by replacing all occurrences of HTTP_COOKIE_VARS in polyglot.php by _COOKIE.

    Thanks for the plugin!

  347. Ama 16. 1. 2006 / 16.03

    Thank you for this great plugin.
    It works fine in my blog, except for categories.
    I have the same problem as Andries, that is to say, how to add the translations of categories to my .po and .mo files with poedit.
    I cannot find it in the poedit help.
    Hope to get a suggestion or indication…
    Regards.

  348. malyfred 16. 1. 2006 / 16.41

    Andries&Ama:: I usually add new lines to .po files in text editor because I haven’t found how to add new string translation neither…

  349. Ama 17. 1. 2006 / 1.26

    malyfred, thank you very much for the tip…

  350. Andries 17. 1. 2006 / 12.50

    thank you malyfred, i’ll try that out

  351. Cezary Kobyliński 17. 1. 2006 / 14.12

    Add to plugin getimagesize(); function to easy read width and size of flag images. Remember, that some server have file-access disabled when using absolute URL.

  352. Pete 21. 1. 2006 / 8.26

    Is there a readme installation guide for WP 2.0 for this plugin. Would love to see/read one if there is one to set it up.

    Please and Thank you.

  353. snaky 21. 1. 2006 / 11.48

    I found a bug in function lp_other_langs. There is two identical parameters in declaration of this function. The last $after parameter has to be $aft for example.
    So you have to modify the lines:
    $after = lang_picker($after); -> $aft = lang_picker($after);

    $other_langs .= $pre“.$foo.”$after”;//fred -> $other_langs .= “$pre“.$foo.”$aft”;//fred

  354. malyfred 21. 1. 2006 / 21.59

    snaky:: It’s fixed since some time ago… but thank you for your bug report.

  355. malyfred 21. 1. 2006 / 22.03

    Pete:: The installation is same for any version of WordPress, you don’t need any special instruction for 2.0. Just unpack it to the “plugins” directory and activate it.

  356. Enno 24. 1. 2006 / 23.33

    Hi malyfred, I was a little busy last time, sorry. I’ll test and write soon. CU and good night, Enno.

  357. René 27. 1. 2006 / 15.39

    Hi,
    Thanks for doing a wonderful job developing and maintaining this plugin.
    I wanted to ask you (or anyone around reading this) if there is a version of the WordPress Default Theme somewhere that has all the English words getexted already? I was just thinking that I was probably not the first one tryin to make Polyglot handle this one correctly, so maybe there is an adapted version uploaded somewhere yet?

    Maybe it would be a good idea also to kind of maintain a list of themes that just work well with Polyglot (those that have the proper function calls already built in or at least the ones having everything gettexted); what do you think?

    Best wishes and regards,
    René

  358. Cezary Kobyliński 30. 1. 2006 / 20.14

    It’s seems that the title of page isn’t translate. It’s a bug?

  359. malyfred 30. 1. 2006 / 21.00

    Cezary Kobyliński:: Comment #203. I’ve suggested this fix to WP developers some time ago but nothing has changed:(

    Anyway, it should work fine without any hacking if you use [lang] tags instead of <lang>.

  360. sudcadred 2. 2. 2006 / 10.40

    I would like to share my know-how about permalinks (I am new to all these things and it took me two days to find out everything). If you use permlinks, there is file .htaccess located in your root directory. Many things is possible to do via this file, but what is important for us, it can translate links, for example, user will see in his browser address http://web/archives/6lang-pref/en/ – this is what we call permalink, but we define in .htaccess rule, how this address is changed on server side to http://web/archives/6?lp_lang_pref=en.

    What rule do we need for this? Very simple – only one line ( I placed it at the beginning of rules, but after RewriteEngine On and RewriteBase /):
    RewriteRule permlink reallink
    In our case it will look like this:
    RewriteRule ^(.*)lang-pref/en/$ /$1?lp_lang_pref=en [QSA]

    Let’s look closer at first parameter permlink (^(.*)lang-pref/en/$). First(^) and last($) character simply mean begin and end of string which should be translated. Next two characters .* are regular expression, and it means any string (. means any character in text, and * means any number of repetitions of previous character). These two chars are enclosed in round parenthesis, it means that it will be remembered as variable in value $1 (next parenthesis would be $2 etc.). Then follows string lang-pref/en/. Then Apache will know, that any address beginning with anything and containing substring lang-pref/en/ will be translated to second parameter (/$1?lp_lang_pref=en).

    $1 is remembered value http://web/archives/, so from this address http://web/archives/6lang-pref/en/ we get http://web/archives/6?lp_lang_pref=en.

    ————————————
    I would write also about Rewrite rule mentioned in comment 194:
    RewriteRule ^(.*)/en/?$ /$1?lp_lang_view=en [QSA]
    This rule generaly could work, but has one big disadvantage. If you use function polyglot_list_langs (as I use in my sidebar to set language globaly for all posts via cookie), part of address is wrong translated to lp_lang_view instead of lp_lang_pref. As a consequence the cookie will not be set, and random language in each post will be displayed.

  361. Dani Danczuk 3. 2. 2006 / 19.42

    Error in my wp-blog-header.php
    Please? Help me!
    http://www.moon-drops.com/log

  362. malyfred 3. 2. 2006 / 22.16

    sudcadred:: Thank you for your “mod_rewrite for dummies” it could help beginners to understand how it works.

  363. TyskJohan 7. 2. 2006 / 18.40

    Here’s a snippet of code that goes deep into the internals of WordPress to finally fix support for in-URI language selection:

    function lang_from_qs () {
    $content = $_SERVER['REQUEST_URI'];

    if (preg_match('/^(.*)\/lang\/([a-z][a-z])\/(.*)$/i', $content, $matches)) {
    #FIXME: What about no trailing slash?
    #FIXME: Does it only occur at the end?
    #FIXME: Check only for defined languages?
    $content = $matches[1] . "/" . $matches[3];
    $_GET['lp_lang_view'] = $matches[2];
    }
    $_SERVER['REQUEST_URI']= $content;
    return;
    }

    add_action('init','lang_from_qs',1);

  364. Catbytes.org 7. 2. 2006 / 19.55

    Bilingual – Tweetalig…

    Zoals je misschien gemerkt hebt, is per deze week de mogelijkheid erbij gekomen om bepaalde blogs in het engels te lezen. Niet alle blogs zullen meertalig worden, dat is teveel werk.
    Of het artikel ook in een andere taal beschikbaar is, is te zien aan …

  365. malyfred 7. 2. 2006 / 20.34

    TyskJohan:: That’s a good idea how to avoid struggling with internal WP rewriting rules! Thank you!

  366. Peter Troxler 8. 2. 2006 / 14.02

    There is a tiny bug in the plugin: the variable $after is used in lp_other_langs() for both the closing tag for each language entry and the closing tag for the list. I changed the closing tag for the list to $closelist.

    snippet of code removed by malyfred

  367. malyfred 8. 2. 2006 / 16.15

    Peter Troxler:: This is fixed since some time ago, but thank you for your report.

  368. TyskJohan 8. 2. 2006 / 20.01

    I don’t know what your release plans are, so I just wanted you to know that I am working on a version with some cleaned-up code but also improved settings/preference editing, based on the separate-screen, akismet style introduced in WP2.0. I doubt that this will be backwards-compatible, though…

  369. tkay 10. 2. 2006 / 3.23

    Just started working on a blog, thanks for a truly great plugin! Good job! One question though; is it just me or is it actually true that the browser language settings override the cookie set by the plugin for the preferred language? Because this makes no sense to me; there’s a great bunch of people who just don’t have a clue that they can implement this kind of a default setting in a browser. Shouldn’t the cookie set the preference over the browser?

  370. malyfred 10. 2. 2006 / 10.50

    tkay:: It takes your browser settings if there is no cookie yet. Then it takes value from the cookie.

    If it doesn’t work like that in your case something is wrong…

  371. Leo 12. 2. 2006 / 12.22

    Hello Malyfred, thanks for your plugin. It’s really great, and i definitely need it. I just start to implement it, so at the very moment i’m translating posts only.
    All seems work as expected, except behaviour of setting language from cookie. On my site all posts are shown in browser preferred language, though wordpress_lang_pref cookie is set. I’ve tested it on two browsers with different preferred languages, and it seems that wordpress_lang_pref cookie aren’t read by browser.
    The problem can be that i have changed the theme a lot, and i don’t use sidebar.php in a single-post-view page?
    Also i want to clarify how to display different images according to preferred language. As a PHP newbie i can suggest that simplest way is to use if-then-else and polyglot_get_lang(). Any advises?

  372. malyfred 12. 2. 2006 / 14.03

    Leo:: What version of PHP do you have? You can try to replace $_COOKIE with old and depreciated $HTTP_COOKIE_VARS if you have some old version of PHP.

  373. Leo 12. 2. 2006 / 19.19

    I’m using PHP 5.1.1, and in output from phpinfo() i can see that $_COOKIE[“wordpress_lang_pref919138a6ea403a63ba984e7f5dc515e5”] exists and is set. Maybe change $_COOKIE to $_REQUEST may help?

  374. Esther 13. 2. 2006 / 12.38

    Hello Malyfred,
    Thanks for the great plugin :-)

    I have a template which uses wp_get_archives(‘type=postbypost&limit=10’) for showing recent posts on the sidebar. What filter could I add to the plugin so it translates that too?
    thanks for your help.

  375. malyfred 13. 2. 2006 / 14.45

    Esther:: There’s no hook in that function so you cannot filter the result at the moment without hacking the WP code:(

  376. tkay 13. 2. 2006 / 22.19

    Seems like me and Leo have the same problem; the cookie is set but for some reason it is either not read or something else causes the blog to fall back to the browser language preference. I have worked on this for a while but so far no luck. The blog reverts back to the browser preference if you click on well basically anything. Weird! Could this be another UTF-8 vs. Notepad -conflict? I have edited the polyglot.php in SuperEdi but everything else in Notepad… I’ll have to check that…

  377. tkay 13. 2. 2006 / 22.32

    Okay. Works. I have 0.99 version of this plugin and there was

    // Initialization stuff

    $lp_lang_pref = (isset($HTTP_COOKIE_VARS[$polyglot_settings[‘lang_pref_cookie’]])) ? trim($HTTP_COOKIE_VARS[$polyglot_settings[‘lang_pref_cookie’]]) : FALSE;

    which i changed to

    // Initialization stuff

    $lp_lang_pref = (isset($_COOKIE[$polyglot_settings[‘lang_pref_cookie’]])) ? trim($_COOKIE[$polyglot_settings[‘lang_pref_cookie’]]) : FALSE;

    Now there’s no problem. No idea how it got there since i havent’s changed that… thought from Malyfreds post that it was the other way around!! Perhaps Leo can get his blog working with this mod as well!!

  378. nukid 14. 2. 2006 / 12.18

    I have no idea how to make this plugin work for my site. I have installed the plugin.

    And what next? I don’t know.

  379. Leo 14. 2. 2006 / 13.05

    tkay:: It’s nessesary to track down how variable is taken from cookie and where it is passed. Maybe, this problem caused by some mismatch between written and read cookie’s name?

    BTW, I’m using WP 1.5.

  380. tkay 14. 2. 2006 / 14.35

    Leo:: I changed the $HTTP_COOKIE_VARS in polyglot.php to $_COOKIE (two references, first line under // Initialization stuff). This solved my problems. I’m using WP 2.01.

    I guess this is not approved by Malyfred since that post of mine is gone? But this worked for me.

  381. Leo 14. 2. 2006 / 15.58

    Problem fixed, i’ve missed comment #346.

  382. Leo 16. 2. 2006 / 10.59

    tkay:: your posts were hidden, thanks for your help though :)

  383. malyfred 16. 2. 2006 / 12.20

    tkay&leo&ALL Sorry guys, this is actually my fault because I haven’t updated the polyglot.zip with the latest version:(

  384. RP 17. 2. 2006 / 18.38

    I have a problem with this plugin.
    at main page:
    http://www.rp.bestcatalog.net/tango/

    language picker doesn’t work – it produces wrong links,

    but if we move to archives or about section it works…

    I’m using “polyglot_list_langs” function to display languages.

    What’s wrong???

  385. malyfred 17. 2. 2006 / 19.08

    RP:: Set the $polyglot_settings[‘lang_rewrite’] to “false”

  386. Leo 18. 2. 2006 / 1.08

    Please delete my previous comment.

    I have found a bug (at least i think so). wp_list_cats() generates for each category unordered list item, where text in <a>…</a> is translated, but text in <a title=”…”> is not translated. Text in title always in default language. You can check it here, at your blog.

  387. Leo 18. 2. 2006 / 1.29

    sorry for a lot of posts

    I mean, than category name in <a title="…"> is not translated, “View all posts filled under ” is translated correctly.

  388. RP 18. 2. 2006 / 11.02

    Thx. It works.
    So simple.

  389. محسن حميدي 18. 2. 2006 / 19.21

    سلام
    فقط خواستم ازتون تشكر كنم
    تون هم به زبان شيرين فارسي
    دلتون بسوزه كه نميتونين بفهميد چي نوشتم
    هر چند شوخي ميكنم
    موفق باشيد
    يا علي

  390. Tara Long 9. 3. 2006 / 10.12

    I’m a bit embarrassed by this newbie question, but nobody mentioned and I am confused:

    How do I get the two different language versions
    in my posts?

    I assumed the plug-in would add another textfield to the edit page/post tool where I could paste the translation in. I tried inputting the tags into the Page Content text area but they were stripped out.

    Thanks in advance, TLL

  391. Escritor 10. 3. 2006 / 23.21

    Hello
    I’m trying to make an archive list by language as I have an archive list by authors and by date in my blog:
    http://blog.karaloka.net

    By authors:

    document.getElementById('authors').style.listStyle="none";
    document.getElementById('list_authors').style.display="none"; // collapse list
    function toggle(list){
    var listElementStyle=document.getElementById(list).style;
    if (listElementStyle.display=="none"){
    listElementStyle.display="block";
    }
    else{ listElementStyle.display="none";
    }
    }

    By date:


    document.getElementById('archives').style.listStyle="none";
    document.getElementById('get_archives').style.display="none"; // collapse list
    function toggle(list){
    var listElementStyle=document.getElementById(list).style;
    if (listElementStyle.display=="none"){
    listElementStyle.display="block";
    }
    else{ listElementStyle.display="none";
    }
    }

    What functions I must to use for a list by languages? What elements? polyglot_list_langs? lang_picker?
    Thank you!
    Regards.

  392. jordi 12. 3. 2006 / 6.50

    Do you have the catalan flag? How can I program it to work with catalan language too?

  393. malyfred 12. 3. 2006 / 20.14

    Tara Long:: You write all language versions in one text field but separate them by adding special tags around them.

    Example:
    <lang_en>English text</lang_en>
    <lang_fr>French text</lang_fr>

  394. malyfred 12. 3. 2006 / 20.24

    Escritor:: polyglot_list_langs prints out the list of languages that are in $polyglot_settings[‘knownlangs’] array.

  395. malyfred 12. 3. 2006 / 20.32

    jordi:: I don’t think there is a catalan flag in default installation but you can easily add it to the “polyglot_flags” directory and its name to the $polyglot_settings[‘flags’] array.

  396. docflo 13. 3. 2006 / 11.09

    since i upgraded to wp 2.0.2 the plugin is broken in every browser but safari. in safari everything works as it should, in firefox etc i get
    Fatal error: Cannot instantiate non-existent class: cachedfilereader in /…/wp-includes/wp-l10n.php on line 67
    what to do?

  397. docflo 13. 3. 2006 / 11.23

    ok, i set wplang to ‘en’ in my wp-config.php and the problem disappeared. strange that before (with 2.0 and 2.0.1) everything worked smoothly without that modification.

  398. Torben 16. 3. 2006 / 21.01

    Hi, nice plugin :-)
    But I also have to problems. The first is the same as in post 17. I want to display the flag symbol at the same line like the date and category, but don’t know how. It was earlier said to add “display: inline” to post-title, but I don’t have that one, maybe because I’m using K2 as a theme? (you can see it here: http://www.tkuehle.de).
    The second thing: When I click on the flag it opens the post in a new window (like when you click on the title). Is there a way to change the language but stay on the actual page (like the example on this page)?

    Hope someone can help me, Torben :-)

  399. malyfred 16. 3. 2006 / 23.53

    Torben:: The easiest way for you is to move <ul>… </ul> with languages into the <small class=”metadata”> </small> and then put:

    .metadata ul {
    display: inline;
    }

    into your style.css file.

    For some other info read comment #182.

    I’ve visited your web and all links seem to open in the same window. There is actually no reason why different language versions should be opened in the new window.

  400. Torben 17. 3. 2006 / 1.25

    Thanks a lot, it works now :-)
    Found out that it works best if i move the code into (like you said) and then remove the and tags.

  401. Torben 17. 3. 2006 / 1.28

    Hmm, don’t know why your blog swallowed parts of my post now… I wanted to say “..move the code into the ‘small’ tag and remove the ‘ul’ and ‘li’ tags.

  402. steven 19. 3. 2006 / 22.52

    just tested the nextpage tag
    together with Polyglot in WP2 and
    it doesn’t seem to work.

    For example:

    some text on page 1

    some text on page 2

    Text auf Seite 1

    Text auf Seite 2

    It would seem that the nextpage tag
    is counted before Polyglot, thus
    displaying too many pages.

  403. malyfred 20. 3. 2006 / 1.53

    steven:: <!–nextpage–> should work if you use it this way:

    some text on page 1
    Text auf Seite 1
    <!–nextpage–>
    some text on page 2
    Text auf Seite 2

  404. aeronova 21. 3. 2006 / 23.08

    Hi, thank you for your awesome plugin.
    I’ve been trying to use it, but it seems not working for me. :( I’m sorry to bother you with my trivial problem, but I’d apprecite it if you could give me some advice.

    Bascially, I installed your plugin, and edit ‘index.php’ of my default theme to add the following code at the end of ‘index.php’ as you said.

    ‘, ”, ”, ”);
    }?>

    Then, I edit ‘polyglot.php’ to add ‘en’ and ‘fr’ for a testing purpose.

    Lastly, I wrote a temporary posting as follows.

    Written in English…
    Written in French…

    However, It turns out your nice plugin is not working correctly as you can see at my blog: home.pusan.ac.kr/~aeronova/blog

    I’m not familar with either wordpress and php. I hope you could save me. Thank you.

  405. malyfred 21. 3. 2006 / 23.43

    aeronova:: Both language tags are there so the plugin looks deactivated.

    Also try [ lang_xx] version of the tags.

    Don’t forget to set WPLANG (e.g. define(‘WPLANG’, ‘en’);) in your wp-config.php.

  406. aeronova 22. 3. 2006 / 7.42

    Thank you for your timely response.
    My problem has gone just ‘Activate’ your plugin. I thought it was already activated, since ‘Action’ was set to ‘Activate’, but it turned out it was not. Thank you again. :)

  407. Seville 23. 3. 2006 / 0.54

    Hey Fred,

    your plugin is awesome! But I don’t get one thing to work. The
    problem Torben had before #399 with opening the post in a new
    window, I want the the post changes in the index.php. I also read
    #182 but it didn’t really help. Like you said I modified the css
    file and I put the

    between the small tags. And then it didn’t show a flag at all. And
    what do you mean by move … with languages…. I don’t
    have anywhere?

    It would be great if you can explain excatly where to put it in the
    index.php

    Thanks in advance

    Seville

  408. Vincent Prat 23. 3. 2006 / 13.35

    Hi,
    I don’t know if this has been reported before but I found a bug in polyglot_the_date, I changed a != into a == in the ‘if’
    [code]
    function polyglot_the_date($the_date, $d, $before = ”, $after = ”){
    global $post,$lp_lang_pref,$polyglot_settings;

    if( isset($polyglot_settings[‘date_format’][$lp_lang_pref]) && $d==” && $the_date==” ){
    $d = $polyglot_settings[‘date_format’][$lp_lang_pref];
    $the_date = $post->post_date;
    $the_date = $before.mysql2date($d, $the_date).$after;
    }
    return $the_date;
    }
    [/code]

  409. malyfred 23. 3. 2006 / 14.40

    Vincent Prat:: This is not a bug this is a desired behaviour of original “the_date” function in WP.

    It returns the date of the post, only if it is different from the date of the previous post. So there is empty string passed to the polyglot_the_date function sometimes and in that case we are supposed to return empty string as well.

    But thank you anyway.

  410. malyfred 23. 3. 2006 / 15.49

    Seville:: It seems that everything works now on your web. Do you know what was the reason for opening post in the new window?

  411. Vincent Prat 23. 3. 2006 / 16.39

    ok, cool. Thanks for your plugin by the way, I use it happily on my site.

  412. Vincent Prat 23. 3. 2006 / 19.11

    Hi,

    I’m getting problems using the feature to say “There’s no version of this post in this language”.

    I guess this has to do with the fact that wordpress always add some [P] and [/P] tags to the post (working with wordpress 2.0.2).

    So the post is in fact never considered empty …

    How do you get around this ?

    It might be possible to just check if the translated text contains html tags only instead of checking if it is actually empty ?

    Any thoughts ? Maybe I am doing something wrong.

  413. Seville 23. 3. 2006 / 21.31

    Hey Fred,

    thanks for your reply, I don’t know if I made it clear. It’s not opening in a new window but it’s opening in a new page. If you go to href=”http://www.schroettle.com/?p=12&lp_lang_view=en and change the language the post is still opening in the index.php page, when I click on my page http://www.derfrison.com to change the language it is opening in the single.php page. How can I make it to open in the same page (index.php).

    Thanks a lot

    Seville

  414. andlaz 23. 3. 2006 / 23.23

    Hi,

    I’m having a problem with the plugin after added 5 new languages on the [knownlangs]. The error is

    “Warning: Cannot modify header information – headers already sent by (output started at c:\inetpub\wwwroot\jukebox\blog\wp-content\plugins\polyglot.php:1) in c:\inetpub\wwwroot\jukebox\blog\wp-admin\plugins.php on line 22”

    It happened right at the point after I added the date format for the new languages.

    Any help is appreciated.

  415. uzbek 24. 3. 2006 / 6.35

    Great plugin. Loving it… That is exactly what I was looking for.. Thanks for the work you have done…

    2andlaz, try to add error_reporting(0); in the begining of your script. That might help…

  416. malyfred 24. 3. 2006 / 12.54

    andlaz:: Comment #172

  417. malyfred 24. 3. 2006 / 13.08

    Seville:: I don’t see any difference from intentional behaviour. If you click on …&lp_lang_view=xx you get the content as single.php in both cases.

    Only on schroettle.com when you click on …&lp_lang_pref=xx you always get home page but that’s a bug that should have been fixed since some time ago. (problem with getting post ID in different versions of WP)

  418. malyfred 24. 3. 2006 / 13.45

    Vincent Prat:: I’ll look at it but try to play around with position of <lang_xx> tags as there should be version that works.

    Testing for html tags wouldn’t work because <img> is also “just” a tag…

  419. Seville 25. 3. 2006 / 3.51

    Oh I see it now,ok, Schroettle.com is the same like I have, but I would like to have it like you. When you click on your website on the flag, the new language version is showin in the index.php and that’s what I want. Or am I wrong?

    Sorry for bothering you

    Seville

  420. malyfred 25. 3. 2006 / 14.41

    Seville:: You are wrong. My single.php just looks the same as index.php, that’s it:)

  421. Daydream 26. 3. 2006 / 7.01

    Hi,
    Just want to show you one possible way I’ve found to show bilingual content…

    voila!

  422. Daydream 26. 3. 2006 / 7.03

    <?php
    $lan = polyglot_get_lang();
    if ($lan==’fr’) {
    include ‘homefr.php’;
    }
    if ($lan==’en’) {
    include ‘homeen.php’;
    }
    ?>

  423. maira 26. 3. 2006 / 15.35

    Hello, malyfred and everybody!
    I have just downloaded the plugin and am testing it on a local installation. I have many things to say but, after reading each and everyone of these comments I’ll just write the most urgent (I think): I have a fully gettexted default theme (Kubrick)and its POT file. Where can I send it? I also can help gettexting others.

    A different matter, but related to this: the standard way to i18nalize a theme is calling load_theme_textdomain() and placing the theme.mo inside the theme folder. Would Polyglot work well this way?

    Thanks, malyfred, for this grat piece of code. I’ll come back soon with more questions and proposals.

    Maira

  424. malyfred 26. 3. 2006 / 19.13

    maira&ALL:: Send the gettexed theme to my e-mail (you can find it in the footer of every page) and I’ll offer it for download.

    I haven’t tried load_theme_textdomain() yet as there are very very few (if any) themes ready for that. But I add it to my ToDo list.

    First on the list is the implementation of full xx_XX language codes – neccessary for smooth co-operation with other i18n stuff.

  425. markus 26. 3. 2006 / 21.43

    Hi malyfred,

    is there a way to get the “lang_xx”-tags working in the Custom Fields?

    Thanks.
    Markus

  426. markus 26. 3. 2006 / 22.25

    here’s my workaround:

  427. maira 26. 3. 2006 / 23.16

    Ok, then I’ll take the calls out of the code and send only the default theme’s files, as I suposse the text strings will have to be included in the general PO file.

  428. SoloWoo 28. 3. 2006 / 7.43

    I have modified the plugin slightly so that it can list known languages in a very clean and neat way, as you can see on the top right corner of the web page below:

    http://www.solowoo.com/?p=174

    Wish this feature could be incorporated in future release.

  429. 囌嚕嗚 SoloWoo.com 28. 3. 2006 / 8.32

    Modified Polyglot…

    Polyglot is a great plugin that gives WordPress multi-lingual capability. This blog, for example, is employing it to make the interface available in both English and Chinese.

    I have modified the plugin slightly so that it can list known languages i…

  430. maira 28. 3. 2006 / 11.23

    I’ve just sent you the gettexted default theme, I hope it can be useful or at least serve as a guide for those wanting to localize their own theme.

    Regarding the implementation of full xx_XX language codes, I’ve found this page with a solution you might like, in case you haven´t tried yet:
    http://www.urbangiraffe.com/2005/07/18/wordpress-localization-menu/

    Polyglot is working wonderfully on my test site most of the time. However, and even though I’m not using permalinks, it redirects to the main page after changing languages from a category page. Is this a known issue we have to live with or maybe there’s a workaround to it?

  431. 囌嚕嗚 SoloWoo.com 28. 3. 2006 / 12.00

    Using Polyglot with Breadcrumb Navigation XT…

    I have been using Breadcrumb Navigation XT and, after installing Polyglot, found that they do not work well with each other. The problem is that Breadcrumb accesses the database directly instead of relying on function calls that Polyglot has added fi…

  432. malyfred 28. 3. 2006 / 14.22

    maira:: Thank you for the theme, I’ll look at it ASAP.

    “redirects…” – that’s known issue. The problem is that native support for permalinks in WP is, in theory, very strong but very poor in the real life. You have to live with it but I am working on ultimate solution for all rewriting issues:) (thanx to suggestion from TyskJohan)

  433. Vincent Prat 28. 3. 2006 / 16.28

    Hi,

    concerning the issue with wordpress post editor always changing the tags: I could not find any solution to get my lang_xx tags in the correct way.

    Which editor are you using ? Any Wysiwyg editor to recommend that could offer you the possibility to edit the source directly ?

  434. Kinkistyle 28. 3. 2006 / 22.36

    To comment 431: Nice catch SoloWoo. I used that bit of code for my “Recent Posts” plug-in and it now translates post titles that show up in my sidebar.

    My guess is that that little hack could work for translating content for almost all sidebar plug-ins.

    Thank you!

  435. malyfred 29. 3. 2006 / 0.23

    Vincent Prat:: I’m not using any WYSIWYG editor in WP, but I have some other plugins installed that possibly fix these redundant <p> tags.

    Try Polyglot 1.3 where I’ve implemented very simple method that should help. Put an empty line between lang_xx tag and a content to make it work.

  436. Leo 1. 4. 2006 / 13.33

    Hello, Malyfred.
    Is there any way to get Polyglot working with Dagon Design Sitemap Generator Plugin? I still can’t realise how do plugins interact…

  437. joe parkin 2. 4. 2006 / 23.37

    hi/hola,

    i have been reading through the comments patiently up until now as i have realised that my eyes are touching the screen from straining so much!

    this plug-in is excellent and is already doing, very very nearly, everything i need it to for my site.

    my site’s not a blog as such. i am using wordpress as part of the website for my new english teaching company in Madrid. I am using it as the front-end of what is essentially a library of all the materials required for our courses but with the ability to leave comments and such.

    My problem is that i need ALL of the text to be translated. I have got pages, titles, comments, menus working but i am having trouble with things like headers or anything that prints out as html from a page template (i hope you get what i mean).

    An example would be the “Leave a Response” header above the input box for a new comment or another would be the text that says “search” above the search box.

    I really appreciate your working in making this great plug-in available and thank you greatly.

    Regards,

    Joe Parkin

    P.S. i’m not exactly an expert with PHP so be gentle with the code!!!!

  438. Vincent Prat 3. 4. 2006 / 11.39

    maly : Concerning the problem for editing posts, I have installed the editormonkey plugin which works well now.

    I found a bug (or a misuse from my side ?) with user’s preferred language :

    Example ->
    http://www.vincentprat.info/wordpress/category/general/?lp_lang_pref=fr
    http://www.vincentprat.info/wordpress/category/general/?lp_lang_pref=en

    You can see that only the titles of the posts (and not the content) get translated to the preferred language. If you click on the flag then the post in the single post view is translated correctly.

  439. malyfred 3. 4. 2006 / 11.39

    joe parkin:: Check: http://codex.wordpress.org/WordPress_in_Your_Language as all these strings should be translated in the .po respectively .mo file and be handled by gettext. Then you have to make sure that all these strings are passed to the WP built in gettext (__("Search") or _e("Search")).

    Second but depriciated option is to call Polyglot for these strings – echo lang_picker_respect_more( "<lang_xx> one language </lang_xxx> <lang_xy> second language </lang_xy>" );

  440. malyfred 3. 4. 2006 / 11.59

    Vincent Prat:: I think you don’t use the tag <!--more--> properly.

    <lang_xx>one</lang_xx>
    <lang_xy>two</lang_xy>
    <!--more-->
    <lang_xx>three</lang_xx>
    <lang_xy>four</lang_xy>

  441. SoloWoo.com 囌嚕嗚 3. 4. 2006 / 17.14

    Polyglottable Plugins…

    I have modified the following plugins so that they would work with Polyglot (i.e. the original ones do not). The modifications are marked between “solowoo begins/ends”, just in case anybody interested.

    Breadcrumb Navigation XT

    Popular…

  442. Fernando A. 3. 4. 2006 / 23.42

    This is one great plugin!
    One question.
    It’s al working though the text is in a different font. It’s a real dull one,…..like it’s quoting.
    You can check it at my site.

    Is there somehtng i’m missing?

  443. malyfred 4. 4. 2006 / 0.28

    Fernando A.:: I cannot check it because it says: “Very soon”, but there is no reason why the text should be shown in the different font.

  444. Vincent P. 5. 4. 2006 / 9.13

    Maly: thanks, it worked :)

  445. andy 5. 4. 2006 / 11.14

    Great plugin!!

    Is it possible to check if a certain language of a post is empty?

    For example: My default language is English, but Post ABC only has a Chinese version of it.

    I want to show the post’s info only if the user is in Chinese mode. If it’s in English mode, I want to disable the empty link:

    Any ideas to do this?

  446. andy 5. 4. 2006 / 11.18

    I think the “empty link” was removed from the post. Here’s what I meant:

    <a href="postABC.html"></a>

    Apologies about that!

  447. malyfred 5. 4. 2006 / 13.01

    andy:: There is already built-in mechanism to show message that certain language version is not available. But I don’t think that the removing of the post completely is a good idea.

    It’s possible though and if you are familiar with PHP and WP – go ahead!

  448. lordjiem 5. 4. 2006 / 13.42

    Hi !
    Your plugin is great (thank you very much !) but there seems to be some incompatibility with the new wordpress widget plugin (on my website, for the less):
    With FR and EN set as lang, when I switch from EN to FR (flag on the bottom of the page), the sidebar losts its “search box” and “categories” widgets. And they come back when switching back to “EN”.
    The most amazing thing for me is that they even temporarily disappear from the Widgets administration panel !
    I will still investigate, but maybe someone could help me ?

  449. andy 5. 4. 2006 / 13.50

    Thanks Malyfred!

    I just looked into the feature, and it looks great. I see that the “text_is_missing_message” replaces the content of the post (i.e. the_content).

    I’m not too familiar with PHP. Would you know how I can replace the title with the text_is_missing_message also?

    Right now, it’s giving me a blank. Any help would be great.

  450. malyfred 7. 4. 2006 / 1.58

    andy:: as mentioned in comment #342 change:

    add_filter('the_title', 'lang_picker_respect_more',1);

    to

    add_filter('the_title', 'polyglot_filter_with_message',1);

    But don’t forget that you get the same text_is_missing_message twice then.

  451. Gavin 7. 4. 2006 / 14.28

    Malyfred,
    I’ve been playing with your great plugin for a while, and I’ve come close to going live with it, but I have some issues.

    1) Even though in my config.php file has default lang set to pt, when I access my site for the first time it always defaults to the english version. Since the majority of my visitors are portuguese speaking, that’s a problem.

    2) As you can imagine, maintaining an updated POT through constant site changes can be a problem (I tend to mess a fair bit with the HTML and headings etc in the templates.) Any prevision for a type template function, like the Gengo plugin has? BTW, been looking at Gengo too, and the thing that keeps bringing me back to Polyglot is that the different versions are kept in the same page.
    Thanks!

  452. Gavin 7. 4. 2006 / 14.49

    Strike that first question… figured out the part about the knownlang default…!

  453. malyfred 7. 4. 2006 / 15.26

    gavin:: You have to translate parts that are gettexed – there is no way around as this is the core feature of WP.

    But you can alway use function: lang_picker_respect_more() which accepts string with all language versions of some text and returns the proper version according to the current users preferences.

    You’ll get a bit nicer name for this function in the next version of Polyglot:)

  454. Dan 10. 4. 2006 / 16.33

    Hi,
    Wicked plugin, however after about 5 hours of trying to figure it out I’ stumped.

    I’m trying to design my template so that it can be displayed in two languages as your plugin allows. I’ve got the posts changing language fine, I’ve created my .mo file and named it correctly, I’ve altered my wp-config.php to set the default. I’ve also tried using e_(“”) to echo my strings based in my template. However none of these seem to want to change the language text to the one defined in the mo file. I have also saved the .mo file as themename.mo in the theme folder and specified it in the index.php file with load_theme_domain(‘name of theme mo file minus extension’).

    I think that I have some problem either with the way I am initialising the switching (using your code above to change the url to lang=en) or my generation of the .mo file and where it is located. Any help greatly recieved!

  455. malyfred 10. 4. 2006 / 18.43

    Dan:: What about this: http://fredfred.net/skriker/index.php/wordpress-fix-for-localization/

  456. Jodok 12. 4. 2006 / 7.39

    I have installed the Polyglot plugin, but got this error:

    Warning: Missing argument 2 for polyglot_the_date() in (xxx)/polyglot.php on line 391

  457. malyfred 12. 4. 2006 / 9.52

    Jodok:: That shouldn’t happen but some plugin probably does weired things somewhere…

    Easy fix – find that line and change it to:

    polyglot_the_date($the_date, $d = "", $before = "", $after = "")

  458. Andries 12. 4. 2006 / 11.45

    @Solowoo and Kinkystyle – 431, 434

    I use the Fuzzy Recent Comments plugin, but my titles are not translated. Could someone tell me where I should enter the code of solowoo to “hack” the plugin:

    “if (function_exists(‘lang_picker_respect_more’)) {
    $result = lang_picker_respect_more($result);
    } ”

    This is the php code of fuzzy comments in pastebin :
    http://pastebin.com/655265

    Again malyfred, tnx for this great plugin!

  459. malyfred 12. 4. 2006 / 14.03

    Andries:: Change line 861 to:

    $post_title = apply_filters('the_title', $post->post_title);

    That is the most general fix which can help other plugins to work as well.

  460. rebecca 13. 4. 2006 / 0.35

    Is there any possible way to have the plugin work if I place <lang_cn> tags directly onto a php file (e.g. sidebar.php)?

    It seems the plugin only works if I use the administration “Write Post” area.

    Is there a work-around somehow to include the tags directly on the php files as well?

  461. malyfred 13. 4. 2006 / 1.32

    rebecca:: As mentioned several times – you can pass that text to the lang_picker_respect_more().

  462. rebecca 13. 4. 2006 / 2.22

    Was anybody been able to integrate Polyglot with EventCalender 3.0 (http://blog.firetree.net/2005/07/18/eventcalendar-30/)?

    I tried using this filter:
    add_filter('ec3_get_events','lang_picker_respect_more',1);

    but it’s not translating the event names. Maybe I’m using the wrong function — I don’t know. Has anybody here been successful with this?

    (BTW, I’m not a PHP expert as you can tell :)

  463. maira 15. 4. 2006 / 4.07

    rebecca: change line 790 of eventcalendar3.php from
    $data['TITLE'] =$entry->post_title;
    to
    $data['TITLE'] =apply_filters('the_title', $entry->post_title);
    or
    $data['TITLE'] =p__($entry->post_title);

  464. borris 15. 4. 2006 / 15.10

    .

    Thank you very much Martin and all contributors for your great great work. Allthough I don’t know much about PHP i got the plugin working in my (still offline) WP-page. I want to have it trilingual english/spanish/german. Three major problems that i wasn’t able to resolve, may be – surely – you know the answer:
    (I’ve installed wp 2.0.2, using the gettext default-theme)

    1. Clicking on Archives or any (test-)post in Categories, the browser shows this message:

    WordPress database error: [You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ‘ )’ at line 1]
SELECT post_id, category_id FROM post2cat WHERE post_id IN (, )

    Tried to solve the problem with your comment 135, but this cancels all bilingual functionality.

    2. It seems ridicoulous but can’t show the flags… my trial-settings:
    polyglot.php:
    $polyglot_settings[‘use_flags’] = true;

    sidebar.php:

    => firefox and camino show text, safari empty image placeholder
    when i put false to both lines, all browsers show text.

    3. The major problem:

    A cklick on the spanish-link in the sidebar destroys the layout.. all links gray, nothing blue, all texts bigger than originally). Clicking english or german is okay.

    Is it a bug in the es.mo file?

    Thanks in advance for any help!!

    borris

  465. Boriel 15. 4. 2006 / 17.26

    Polyglot does not currently translate the title of the page (The title displayed in the browser window).

    To fix this, just add the following line:
    add_filter(‘wp_title’, ‘lang_picker_respect_more’, 1);

    into the polyglot.php file, and use the scheme, instead of the for the categories.

  466. Boriel 15. 4. 2006 / 17.28

    Hmmm. My tags wrapped, I meant:
    …and use the [ lang_XX ] scheme insted of the <lang_XX> one.

  467. borris 15. 4. 2006 / 17.47

    hi again

    … tracing the problem described in post 456:

    concering 3.: with any langunage (i tried en, de, fr, pt, ja) it works, but is doesen’t work too with ca (=catalan), that really strange!!

    i tried the classic layout and everything is fine – am i right that the problem is dealing with the gettexted kubrick theme?

    best regards

    borris

  468. borris 15. 4. 2006 / 20.38

    hola boriel
    thank you very very much, it works perfectly now!
    but do you have an explication why only the spanish didin’t work?
    cordialmente borris

  469. boris 15. 4. 2006 / 22.45

    hi again,
    pages work fine, but clicking Categories or Archiv still produces the sql-error-message :-(
    any further idea? thanks in advance and best regards
    b.

  470. borris 16. 4. 2006 / 1.44

    hi again,
    hope you don’t mind, this is going to be a long comment, in order to inform about all the steps i did trying to resolve the problem described from 464 up tp here:

    1. I’ve installled the spanish wp 2.0.1. version. Apparently everything ok.

    2. Installed and activated the gettext_default theme: sidebar-layout “destroyed”, click on Archiv and Categories produces sql-error

    3. Changed language in wp-config from ‘es_ES’ to ‘en’: the text of the search-button changes to english

    4. Re-activation of the (spanish) default theme: Archiv and Category ok. Change of WPlang in wp-config only affects the admin-area/backend

    5. Installation and activation of the Polyglot plugin. So far no languages, but no problems with sql

    6. copying fr.mo and de.mo to the languages-folder. no problems.

    7. $polyglot_settings[‘knownlangs’] = array(‘en’,’es’,’fr’,’de’); => the spanish default-category “General” (i think it’s “uncategorized” in english) changes to german (“Allgemein”). No other changes. “Categorias” itself (spanish) stays spanish. If i delete ‘de’ from the knownlangs, “Allgemein” returns to be shown the spanish “General”.

    8. In order to change between the languages i copy to the sidebar (spanish default-theme) the following code:

    9. Clicking now the language links change the month in Archives, the login/logout-text and the default-category. no sql-errors.

    10. activation of the classic-theme, again pasting the code to the sidebar: everything seems to be okay

    11. new page

    title:
    Page one EN

    content:
    first new page

    works fine withe classic and the default theme, no sql-errors cklicking Archives or Categories

    12. new post

    title:
    Comment one EN

    content:
    first new comment

    works fine withe classic and the default theme, no sql-errors cklicking Archives or Categories

    Fundamental functional differcnce between the two themes: classic shows the top-menues (pages, categories, archives) in each language. I supose that’s dealing with the gettext stuff….

    13. now another activation of the default_gettext theme:

    – without new code in the sidebar.php: main menu items appaer in english (Pages, Archives, Categories), the first page is spanish, as installed. Clicking Archives or Categories produces the sql-error message:

    WordPress database error: [You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ‘ )’ at line 1]
SELECT post_id, category_id FROM wp_post2cat WHERE post_id IN (, )

    – pasting this code into sidebar.php

    brings the following result: fully translated menu, possibility to read in each language the formely generated page and comment – but: sql-error-log cklicking Archives and Categories and, clicking the spanisch link in the sidebar destroyes the sidebar layout

    14. last hope, boriel’s advice pasting to polyglot.php

    add_filter(‘wp_title’, ‘lang_picker_respect_more’, 1);

    but it doesn’ resolve the probelm…

    15. My conclusion:
    or there is a bug in the es.mo (same problems if i rename it to sp.mo or anything else and change the polyglot.php accordingly)
    or there is a bug in the default-gettext theme.

    Unfortunateley, i’am unable to detect nor to resolve it, so any help of you would be very very welcome!!

    thanks in advance
    b.

  471. Ann 19. 4. 2006 / 7.33

    Is there any way to add a filter to the comment links for each post? Right now the popup titles that link to the comments show the full titles with lang tags, eg. “Comment on blahblahinaa” instead of parsing the title languages.

  472. malyfred 19. 4. 2006 / 10.54

    Ann:: No filter for this:(

    Problem is in comment-functions.php on line:

    echo ' title="' . sprintf( __('Comment on %s'), $post->post_title ) .'">';

  473. Boriel 22. 4. 2006 / 12.25

    Ann (471) and malyfred (472):

    There is no filter for that, but you can make a workaround for it:

    Within the Loop, and just before calling the comment-popup-link, add the following:

    <?php
    global $post;
    $post->post_title = lang_picker_respect_more($post->post_title);
    ?>

    After that, you can call the comment function as always:

    <?php comments_popup_link(‘No Comments »’, ‘1 Comment »’, ‘% Comments »’); ?>

    This will translate your post title for each post before calling your comment popup, and your page will validate XHTML. :)

  474. StuFF mc 24. 4. 2006 / 13.39

    I need a way to only show the posts that have a content for the selected language… Because my website is for the same podcast in 3 different languages and the french visitors does not want to see the german podcast (for example)

  475. malyfred 24. 4. 2006 / 15.30

    StuFF mc:: Ok guys, I see that there is no way to persuade you that you should not hide content of your web from your visitors:)

    I’ve added this feature to my ToDo list…

  476. brian anderson 25. 4. 2006 / 22.11

    I’m working with a client that wants to use

    <chinese>these words in chinese</chinese>

    instead of

    <lang_cn>these words in chinese</lang_cn>

    Is this possible?

  477. malyfred 26. 4. 2006 / 12.50

    brian anderson:: well, with a bit of hacking – it is possible. Find the line whre the tags [ ] are processed in ‘polyglot_filter’ function and add there very similar line which replaces your custom tags with the proper version.

  478. Boris 28. 4. 2006 / 14.32

    Hi,

    I’m new on PHP i’ve installed Polyglot on my girlfriendds site and want to hide any text from index.php (like: Friday, April 28, 2006, filed under …) when no Title and post specified in some language?

    Thanks in advance.

  479. Alexander 30. 4. 2006 / 18.36

    Thanks! Good manual

  480. David Greg 18. 5. 2006 / 13.26

    Is it possible to stop the WP admin from switching languages I only want the language switch to work on the actuall website?

  481. malyfred 18. 5. 2006 / 20.24

    David Greg:: Not at the moment. I can add this feature to the future release.

  482. Wojtek 19. 5. 2006 / 11.52

    Gret plugin – it works form the start :) (which is not always obvious).

    I read all the comments above and (if I doid not mis anything) I have a small question:
    Is there a way to always present a post in a fixed language (say, pl), no matter the settings in the browser of the reader?

    The rational is that most of my posts in Polish are complete (and readers will make the effort to understand them) and I just usually publish a summary in Emaglish or French.

    Thanks!
    Wojtek

  483. malyfred 19. 5. 2006 / 12.08

    Wojtek:: just don’t specify the language for the parts of the text that should be always shown and you get what you want.

  484. Wojtek 19. 5. 2006 / 12.42

    @malyfred: thanks for the super-fast answer.
    I though of this initially, however I still would like to keep posts in different languages separated. Therefore the scenario I am looking for is to always display the Polish version to everyone initially, and then if someone would like to see the translation — to give them the ability to click on the flag.

    If this is not possible then I will go ahead with your suggestion (though that bay be an entry for the “wishlist” :))

    Thanks – Wojtek

  485. Wojtek 19. 5. 2006 / 12.45

    small update to my entry: the last but one line should read:
    ” … — to give them the ability to click on the flag and see only the translation”

  486. Remco 22. 5. 2006 / 14.33

    I’m implementing Polyglot and it works beautifully!

    A few problem sofar: I cannot get it to translate the link category titles, generated by get_links_list. I tried adding the tags and I tried using translations in my mo file. Both don’t work.
    I have the same problem with the link/linkdescriptions in the links list.

    Any suggetions? Thanks!

  487. malyfred 22. 5. 2006 / 15.01

    Remco::

    visit: http://codex.wordpress.org/Template_Tags/get_links

    and then try:

    echo apply_filters('polyglot_filter', get_links(blabla...,false));

    or

    echo polyglot_filter(get_links(blabla..., false));

  488. Remco 22. 5. 2006 / 16.06

    Malyfred:
    Thanks, tried your approach but cannot get it to work.

    First, I would like my links in a list with the category titles to show, so get_links_list is what i would need en not get_links. I tried it anyhow, to see if I could get the links itself to translate. But can’t get that to work either.
    -do I need to change anything in polyglot.php?
    -should your approach work with or tags or with mo file translations?
    -should your approach also work with get_links_list, or only with get_links?

    I would be very happy with links category titles to translate, and extremely happy if the links and link descriptions would work too.

  489. malyfred 23. 5. 2006 / 0.52

    Remco:: As far as I know, there is no way to get it work with get_links_list unless you edit the code of that function:(

    The idea is that get_links() should be good enough to produce any kind of list that you could possibly wanted.

    You don’t need to change anything in the polyglot.php, just add all language versions directly into the link title and description.

  490. john 23. 5. 2006 / 7.56

    Hi Malyfred,

    My Chinese font is so small, but I would like to keep the English font (the primary) the same size as I have it now.

    Is there any way I can enlarge the Chinese font without changing the size of the English font?

  491. malyfred 23. 5. 2006 / 10.36

    john:: comment #134 and a two lines of PHP could help you to include different style sheets for different languages. You can define then the font size as you need.

  492. Remco 23. 5. 2006 / 20.26

    Hi Manfred, thanks for your answer on 489.
    As far as I can tell, get_links() cannot get the link category titles. (I’ll check it again to be totally sure). In get_links_list() these titles are generated in H2 tags.
    You are right I can get the links themselves in every possible format.

    You should consider a polyglot-optimized set of template tags, for those users that are more interested in the full polyglot functionality than in upgradability of their wordpress installation.

    Thanks for the good work anyway. I already can translate more on my site than I possibly would have believed before. Too bad I cannot go all the way -yet.
    See my site (under construction, not too many translations yet) at: http://www.steppingstonesforafrica.org

  493. glittersoul 24. 5. 2006 / 4.53

    Hi, I’m having trouble getting polyglot2 to work for me.. is there some sort of admin interface that I access? please e-mail me and let me know because I’d love to get some translations up :)
    Thank you!

  494. Remco 24. 5. 2006 / 16.06

    Hi, Back again. For the people struggling with the same, I found a solution for the translation of the link category titles, by using the function get_linkcatname(). It is not documented in the codex, but works like:

    This gets the translated link category title. Then below the title, use get_links().

    Further, after reading back all the posts above, I tried to get my links and link descriptions to translate using:

    ‘,”,”, false, ‘id’, true, false, 10, false, true)); ?> (as you suggested)
    and
    ‘,”,”, false, ‘name’, true, false, 10, false, true)); ?> (as I read somewhere here above)

    but none of these work. All I get is the links and linksdescriptions in both translations with tags around them.

    Am I doing something wrong here?

  495. Remco 24. 5. 2006 / 16.53

    My code in the previous post was cut off: I meant to write:

    echo apply_filters(‘polyglot_filter’,get_links(1,”,”,”, false, ‘id’, true, false, 10, false, true)
    (as you suggested)

    and

    echo lang_picker_respect_more(get_links(1,”,”,”, false, ‘name’, true, false, 10, false, true)
    (as I read somewhere here above)

  496. malyfred 24. 5. 2006 / 17.14

    Remco:: You should read carefully what I write… please note the FALSE as the last parameter in my example (comment #487).

    All parameters are explained in the codex on the address that I have suggested above as well.

  497. rags 25. 5. 2006 / 11.52

    Hi thx for this nice plugin – the translation of pagetitles and blog posts work for me.

    I have the following goal:

    If a user choses his/her site language, the comments on a multilingual blog post should also be marked to belong to the users language and the comment-thread should only show the comments written in that language. If the site language is changed by the user, the comments written in the chosen language should appear (I dont like the language mix in the comment thread).

    Is this possible, using Your plugin?

    Thx for hints

  498. Remco 25. 5. 2006 / 12.25

    Hi Malyfred,
    I DO read the codex, all the time :-). But I didn’t read your comment carefully enought, thought it was like an example. I’m not really a php hero, but I’m learning fast this way. Thank you very much for pointing out my error to me. All links and link descriptions translate beautifully now, which is fantastic.

    As to my comments in 494 about the link category titles (for those interested), my code didn’t come through, I meant to write

    echo apply_filters(‘polyglot_filter’,get_linkcatname(2));

    where 2 is the link category id.

  499. malyfred 26. 5. 2006 / 11.34

    rags:: Mark all comments is easy. Filter only comments written in certain language is not that easy but it’s feasible. Both require some advanced hacking in the Polyglot’s code.

    But as I said several times here – I really don’t think it’s a good idea to hide some content of your web from your visitors. There are many people around who speak more than one language and you force them to check you web with several different language settings if they want to read all comments.

  500. glittersoul 27. 5. 2006 / 8.17

    In case e-mail isn’t preferable, I am still checking back here. Can anyone please let me know how I access the admin panel (if there is one for polyglot2, which is what I’ve installed)? I’m rather confused at this point so any help would be appreciated. Thank you :)

  501. malyfred 27. 5. 2006 / 10.01

    glittersoul:: there is no admin panel for Polyglot. You must set everything directly in the polyglot.php.

  502. glittersoul 28. 5. 2006 / 7.11

    Oh, I see, well thank you, that clarifies where I must be messing up, then. I wasn’t sure if I’d missed some major part of the process of set-up. I appreciate the information.

  503. Triqui 29. 5. 2006 / 3.26

    I managed to solve the problem of having WordPress in two (or more) languages in a rather new way, check it out if you think it can be useful
    http://www.emanueleferonato.com/2006/05/26/wordpress-in-two-or-more-languages/

  504. Remco 30. 5. 2006 / 17.52

    I was wrestling with translating the time-since plugin with polyglot, as in my language (Dutch), the plural of for example ‘week’ is not ‘weeks’, but ‘weken’. The way the plugin is written assumes plural is just adding an s, but in Dutch that is not the case, makes it difficult to get the terms translated by polyglot/gettext via the .mo file. So here is a tip if in your language you have the same problem: download the Dutch translation of the time-since plugin here and change the dutch singular and plural to your language.

  505. Remco 30. 5. 2006 / 17.54

    …forgot to add to my last post:
    And in the time-since.php file, add __() around the terms for days/months etc. and around the en (and).

  506. eduardo 31. 5. 2006 / 8.50

    Hi,
    I am trying to use your plugin for the first time, v2.0. Some problems found, though:
    The plugin seems to choose the language according to the browser setting, and chooses the correct text. It also shows a flag for the other language. But the flag leads nowhere: if not using permalinks for language viewing, i land in the original post. If using the permalinks, the plugin fails to add the trailing slash to the original post name before adding the URI hepers, so i incur in a 404 error. If i then edit the URI in the browser navigation bar, i again get a 404.
    Any ideas?
    (ps. i have deactivated it to keep the page looking right).
    Thanks!

  507. eduardo 31. 5. 2006 / 8.56

    Oops, i forgot to mention: i use other plugins to deal with permalinks. One is “enforce www preference“, and the other one is “permalink redirect“, and also “redirect old slugs“.
    Thanks!

  508. Stian B. Barmen 31. 5. 2006 / 15.32

    I am trying to set up polyglot on my mother cabin for rent page, dev version now at http://eagledev.barmen.nu.

    It mostly works fine, but the Title and Tagline is not translatable. Any ideas? I can of course code them myself into the theme, but maybe there is a better way?

    Of course I tried the approach. :)

  509. Joe Parkin 1. 6. 2006 / 7.39

    Hi,

    I’ve been working on my site for a while now with polyglot and i am generally more than happy with it and would like to thank you again for having made it for us!

    I left a message once before about not everything on the page getting translated. Apparently I need to change the .po or the .mo file and add what I want. Is there an editor available for Mac OSX? I read somewhere that you need an editor and neither dreamweaver nor textedit would open it.

    My other problem is that, although i have increased the number of characters allowed in the category name in my WP database, it just shows up as the whole thing i.e. with the tags and both languages.

    Thanks to all in advance,

    Best wishes,

    Joe Parkin

  510. malyfred 1. 6. 2006 / 10.46

    eduardo:: You probably don’t have trailing slash in your “Customize Permalink Structure” – add it there. If you have it there then Permalink Redirect plugin is probably doing some weird things.

    Collision with other permalink plugins is pretty probable because the permalinks are not handled in WP in a very nice way so the authors of plugins have to find workarounds. I’d recommend finding wich plugins don’t work together and not using one of them.

    The other option is to find out how they are handling permalinks and there will be probably easy way how to fix it.

  511. malyfred 1. 6. 2006 / 10.59

    Stian B. Barmen:: One hook for that was missing in Polyglot. It’s fixed now so just download the current version of Polyglot and it should work fine.

  512. malyfred 1. 6. 2006 / 11.10

    Joe Parkin::: Check http://www.poedit.org/, it seems that they are working on Mac version.

    The .po file is just plain text file so you can edit it in any text editor and then “compile it” – http://www.gnu.org/software/gettext/manual/

    What function do you use in your template for showing categories?

  513. eduardo 2. 6. 2006 / 2.15

    Hi Malyfred, thank you for your reply.

    Indeed i didn’t have the trailing slash in my permalink structure. I supposed ou function polyglot_trailingslashit() would take care of that, isn’t it so?
    Well, i added the trailing slash to my structure (not very sure if that is correct tough, because this way a post will look like a directory in the browser’s address bar). The links generated by polyglot got ok.

    I the turned off all 3 plugins that dealed with permalink (the ones i mentioned), but unfortunately your plugin still doesn’t work! It chooses the right text and generates the flag-links to other languages, but the link lands in a 404… odd.

    Any help will be much appreciated!
    (i have turned all back to normal in my site, if you need to see the problem tell me and i will make it appear to you)

  514. malyfred 2. 6. 2006 / 19.40

    eduardo:: I’ve found what’s wrong – your version of WP is too old. New Polyglot’s permalink functions relies on stuff that has been introduced in version 2.0.

  515. eduardo 3. 6. 2006 / 13.19

    hey Malyfred,

    I see. I should take a while more to update my WP, there are a few things wrong with WP’s internationalization that i have managed to compensate for in WP 1.5, but i still didn’t find a way in 2.0 (like for example: there is a “category base” variable in it’s permalink structure, but there is no “author base”, so we are stuck with the english word “author” is the URIs).

    So can i use an older Polyglot version? Does version 1.3 work with WP 1.5.2?

    Thank you for your help. It is now important to me to translate many posts to other languages.

  516. eduardo 3. 6. 2006 / 13.33

    Take a look here please:
    http://trac.wordpress.org/ticket/301
    http://trac.wordpress.org/ticket/1762

  517. Remco 3. 6. 2006 / 18.52

    Hi Maleyfred,
    I have a problem getting the names of the months translated. In theloop.php and in sidebar.php, there are the sentences like: You are currently browsing the archives for May, 2006. I can get all the words translated using _e(), but the month name won’t translate. It uses: the_time(‘F, Y’);
    In locale.php, the months are written like this: $month[’05’] = __(‘May’);
    So I thought the months should translate when I put the proper translation in the .mo file. But it doesn’t work. Could you help me out? thanks in advance.

  518. malyfred 3. 6. 2006 / 22.29

    Remco:: Well, turn off time settings in Polyglot – it could help. The problem is that WP developers don’t care about other languages than English so they use PHP funciton date() which is useless for i18n.

    I already have a workaround for this but I don’t have a time to implement it at the moment.

  519. Remco 4. 6. 2006 / 13.15

    Hi Malyfred,

    I turned off time settings (everything in between ‘time-functions’ comments in polyglot.php) in Polyglot, which didn’t help.
    Tried everything in my sidebar.php, including using other functions like get_single_month etcetera, all didn’t help.

    Then, I tried to analyse what happens. I discovered, if I set WPLANG manually to my second language (nl) in wp-config.php, everything, including month names (!) translates perfectly if choosen nl as language on the site (Of course I can’t switch back to english then).
    The same with Polyglot plugin turned off (of course posts don’t translate then).

    So my conclusion is that somewhere in the switch of WPLANG by polyglot, the month/date/time isn’t switching, which is switching if WPLANG is set manually. (sorry for my non-programmers phrasing).

    Do you have any more suggestions based on my conclusion?
    Could you be more specific about which rules/functions in polyglot I could try to turn of?

    Reading your remark about the date function, I read around in the codex, and I found some people talking about a function called date_i18n(). I wouldn’t know how to use it, but could this help?
    From the codex it looks like they are really putting an effort in making WordPress translatable.

  520. thurner rupert 7. 6. 2006 / 10.56

    we use polyglot, but there are two little things we would like to have:
    * activate the flags, it did not work
    * two additional lanuguages, als (http://als.wikipedia.org), and rm (http://rm.wikipedia.org/)

  521. WordPress mehrsprachig - flying sparks 7. 6. 2006 / 11.46

    […] Christian Strang beschreibt seine Erfahrungen mit dem Plugin Polyglot. […]

  522. Rodrigo Contreras 7. 6. 2006 / 16.20

    Hi, Malyfred. This plugin is awesome!
    But my RSS feeds are still buggy.

    The description and category tags don’t get translated and both show the original full string like the following:
    hello

    In the web page they work fine.
    I read all the comments and did what’s suggested, but nothing…

    I’m using WP 2.0.2 and Polyglot 2.0.

    A re-worked RSS config tutorial would be appreciated.

    :)

  523. Boriel 7. 6. 2006 / 21.21

    Rodrigo, I fixed that.
    Add the following lines to polyglot.php:

    add_filter('the_category_rss','lang_picker_respect_more',1);
    add_filter('the_category_rss', 'polyglot_lang_picker_htmlentities',1);
    add_filter('the_category_rss','polyglot_translate_the_category');

    I’m using Polyglot 1.3.

  524. mauro 10. 6. 2006 / 6.29

    Hi, many thanks for your useful plugin.
    I solved the problem of Recent Posts list. Because of lack of hook in wp_get_archives, I hackedan an old routine by Nick Momrik (thanks) to get recent posts list.
    I inserted two lines of code to call a polyglot function and translate the post title.
    The whole stuff is a little long, so http://www.maurograziani.org/wordpress/polyglot-and-recent-post-list/

  525. tzMartin 11. 6. 2006 / 6.12

    Those using the ‘Top10’ plugin from weblogtoolscollection

    I have modified the plugin so that it will work with Polyglot. The modifications are marked between “Polyglot begins/ends”. Just cut and paste this function below into the Top10.php plugin:

    function show_pop_posts() {
    global $wpdb, $siteurl, $tableposts, $id;
    $results = $wpdb->get_results("select postnumber, cntaccess from mostAccessed ORDER BY cntaccess DESC LIMIT 10");
    echo "";
    if ($results) {
    foreach ($results as $result) {
    // Polyglot begins
    if (function_exists('lang_picker_respect_more')) {
    $result->postnumber = lang_picker_respect_more($result->postnumber);
    }
    // Polyglot ends
    echo 'postnumber).'">'.lang_picker_respect_more(get_the_title($result->postnumber)).' ('.$result->cntaccess.')';
    }
    }
    echo "";
    }

    If you have problems, you can download the mod file here:
    http://www.tzmartin.com/downloads/wordpress/plugins/top10.phps

    (just rename the file and upload it to your ‘plugins’ folder.)

  526. cosmin 15. 6. 2006 / 5.13

    im gonna using wp

  527. yhtsai 18. 6. 2006 / 12.14

    Hello Malyfred,
    I wrote a polyglot plugin under b2evolution named PolyglotX, porting from your Polyglot plugin.
    Thanks for your idea!

  528. Hiddenson 19. 6. 2006 / 15.01

    Hi,

    I upgraded my WP installation from 1.5 to 2.0. As far as I know, the plugin was working perfectly then, but now I get a strange error on only certain entries, as you can see in http://construct.hiddenson.net/page/4/

    For some reason, two posts are out of design. I figured it was the new editor, so I disabled visual and changed tags into [lang]. It did not help.

    Any ideas?

  529. malyfred 20. 6. 2006 / 1.05

    Hiddenson:: Did you upgrade to the latest version of Polyglot (2.0)? If not, do that as it is highly improved and fixes many potential bugs.

    I don’t think that your problem is actually caused by Polyglot though because all code generated by Polyglot is valid and looks as it is supposed to look like…

  530. Jerome Charaoui 20. 6. 2006 / 15.10

    Using Polyglot 2.0, the month names in WP functions (eg. wp_get_archives) were not getting translated. I found a rather simple way to fix this :

    In polyglot.ini add the line include(ABSPATH . WPINC . '/locale.php'); after load_default_textdomain();

    Also, in your locale.php add the line global $weekday, $weekday_initial, $weekday_abbrev, $month, $month_abbrev;

    I think this might be a bug in WP (using 2.0.3 here) because variables like $month are global throughout the code, except in locale.php… They should be declared global in that file as well, methinks…

  531. Jerome Charaoui 20. 6. 2006 / 15.12

    Forgot to mention a detail about the previous fix : make sure you add the line global $weekday, $weekday_initial, $weekday_abbrev, $month, $month_abbrev; at the beginning of the file, before the variable definitions! Otherwise it won’t work.

  532. Remco 21. 6. 2006 / 11.21

    Jerome,
    thank you VERY much for posting this solution! It works beautifully. It was the last problem I had with translating my site. (I described my struggles with it in post 519).

  533. malyfred 21. 6. 2006 / 12.28

    Remco&Jerome Charaoui:: Good for you if it works as you need.

    But I don’t think it fixes translation of all dates in WP because they usually use PHP date() function which IMHO doesn’t work with other languages than English:(

    I’ll publish next version of Polyglot with unversal date&time fix as soon as I finish my uni degree.

  534. Remco 21. 6. 2006 / 15.09

    Malyfred good luck with your degree. thanks for the good work.

  535. Max 21. 6. 2006 / 17.15

    Hi Malyfred,

    Is it possible to fully translate the RSS feeds?

    At the moment my RSS ‘pubDate’ tags always come out in an English format and my RSS ‘language’ tag is always set to ‘en’.

    Many Thanks, Max

  536. Jan 25. 6. 2006 / 15.28

    hey could someone pls help: i cant get default language german to work with my site !
    wp version 2.02, the german de.mo file is in its place and
    define (‘WPLANG’, ‘de’);
    is set correctly, the admin interface is correctly german.

    but for some f*ckin reason the polyglot settings are screwed ?
    – version 1.3 (because 2.0 ruined my permalink structure ??)
    – $polyglot_settings[‘default_lang’] = ‘de’; is set

    what more do i need ? have a look at http://www.grnch.de , its still showing english posts as default ! i want my german, please….

  537. Jean-Marc 28. 6. 2006 / 22.11

    Hi Malyfred,

    First : thanks a lot for that enormous job.
    I’ve a question about .
    The site I develop is destinated to be used by redactors knowing nothing about html and/or php coding, also bd using.
    I need then a really simple way to use the plugin by them.
    Of course, using is not difficult, but I’ve got 2 problems with it :
    1. Using the default WP wysiwyg, there is no problem at the first save. But if when editing a post, marks are disapearing when the post is recorded.
    Knowing that wysiwyg is not the best, I tried Xinha, what’s working good. But Xinha add a / in the marks. becomes and is not recognised anymore by Polyglot.
    Do you know a solution or a wau to create a button, like code button on forums?
    2. Because redactors will not be admin in that site, I can’t (and I don’t want) to ask them to add lines in .po file and compile it and upload it for new categories. Imagine what will be the site if one of them makes a procedure mistake and upload a bad .mo file …
    Second solution : marking categories name. In that case, maks disappear when record. The only solution I finded till now is to add marks directly in the database via phpmyadmin, but I don’t want redactors go in the db (You understand why …).
    Do you know that problem or is it just mine? In that case, how to solve it?

    Thanks for help and for plugin,
    Jean-Marc

  538. malyfred 29. 6. 2006 / 9.08

    Jean-Marc:: I’d say that you can solve both your problems easily – use [lang_xxx] instead of <lang_xxx/>

    [] tags are not modified by WYSIWYG editors and work for category names as well. Please check the “How to translate categories” part of the original post for more details.

  539. Jean-Marc 29. 6. 2006 / 21.19

    Hi Malyfred,
    Thanks for that fast answer. I didn’t saw that.
    I’ve read “hotw to translate categories, but it’s written with what I tried. I didn’t tried [].
    With [], it works fine.
    I don’t wnat to need to use .mo for translating categories because redactors of the site know anything about .po, .mo files and I don’t want to let them “play” in files.
    The only problem I have now is in the archives.
    The site write :
    Archive for the Category ‘ unclassified’

    The line in my archive.php that write the cat name is :

    Is it possible with a cat named unclassified to have just Unclassified for english ?

    Thanks for help and for plugin,
    Jean-Marc

  540. Sandy 10. 7. 2006 / 23.11

    Hi,
    My plugins runs very well. Thank you so much, Malyfred.

    However, I have a question is, why my titles of posts in Archive Page display whole the text as well as the code

    Plz take a look here:
    http://blog.camtvlive.com/category/my-writing-task/poems/

    But it display perfectly on the sidebar and on my Stats pages. But this problem still happens with the title of posts.

    Here is my stats pages.
    http://blog.camtvlive.com/wp-stats.php

    There are some func. of stats page, and I try to add hooks for them as follows:

    add_filter(‘the_excerpt’, ‘lang_picker_respect_more’,1);
    add_filter(‘display_stats’, ‘polyglot_translate_the_category’,1);
    add_filter(‘get_recentposts’, ‘polyglot_translate_the_category’,1);
    add_filter(‘get_recentcomments’, ‘polyglot_filter_htmlentities’,1);
    add_filter(‘get_mostcommented’, ‘polyglot_filter_htmlentities’,1);
    add_filter(‘get_mostemailed’, ‘polyglot_filter_htmlentities’,1);
    add_filter(‘get_highest_rated’, ‘polyglot_filter_htmlentities’,1);
    add_filter(‘get_most_viewed’, ‘polyglot_filter_htmlentities’,1);
    add_filter(‘wp_list_pages’, ‘lang_picker_respect_more’,1);
    add_filter(‘get_recentposts’, ‘lang_picker_respect_more’,1);

    But nothing happens. Please help me.

    Anyway, thank you very much for your super plugin, malyfred.

  541. Wojtek 17. 7. 2006 / 23.14

    Greetings – I have a weird problem and I did not see it in the list above.

    If you look at http://blog.swiatek.name, you will notice that some posts, even though they have a Polish version show in the English one (pl is default). I spent hours trying to understand why some behave like this and some other are fine.
    The flag in the case of the bad ones is always British (even though the post is in English).
    In the single post view everything is OK.

    I traced it down (looking at the source of the page) to an extra being appended at the beginning of th epost (and not processed by the plugin). It i snot in the source of the blog entry (I even changed

  542. Andrew da Silva 22. 7. 2006 / 23.51

    Hi!

    I installed your plug-in on a single column without the sidebar. And it worked great!

    Now I tried installing it on the K2 theme.. and it does not translate the Sidebar menu.. it shows the tags and both languages..

    Can you check out the URL and tell me what could be wrong?

    Thanks!

    http://prdq.qc.ca/

  543. Jimy 25. 7. 2006 / 16.19

    The necessary plugin (:
    It is established easily and perfectly works.
    Thank u so much!

  544. Wojtek 30. 7. 2006 / 19.38

    Please discard my previous post. i found the problem: adding a entry (to cut the text displayed on the main page) completly disorganizes Polyglot.
    For non-Polish browsers ([pl] is the default) the title is in English and content in Polish.
    Any idea what went wrong? :)
    Thanks – Wojtek

  545. Wojtek 30. 7. 2006 / 19.59

    Ha – maybe the should be “bare”? (ie. not enclosed within brackets?)
    Looks so

  546. eduardo 10. 8. 2006 / 16.37

    Hey Malyfred,
    I have been using your plugin for a while successfully, it is great.
    I would need your assistance with something. I use as the page title (the one in the header section of the html) the following:
    wp_title(''); bloginfo('name');
    This is good if there is only one language in the post title, but it will show both languages if there are two of them.
    You can see it here as an example.
    The same happens when using Extended Live Archives, please take a look at the same post title in the archives index that is displayed in this page
    Is there a way to correct this?
    Thanks a lot.

  547. Ruben 10. 8. 2006 / 19.52

    Hi.
    First of all, thank you for your wonderful plug-in.
    I’m currently trying to implement it for a Korean, English, and Spanish blog. I followed all the instructions on this page including editing single.php, search.php, and index.php. I edited wp-config.php, and the polyglot.php as well. Then, i tried gettext by using poedit but after that
    Fatal error: Cannot instantiate non-existent class: cachedfilereader in /home/.fudge/rubenhan/mapsketcher.com/wp-includes/wp-l10n.php on line 67
    This error occurs. Could you help me out what’s the problem? Thank you.

  548. malyfred 11. 8. 2006 / 12.01

    Sandy&ALL: Sorry for late answer.

    Sandy – your stats are generated by plugin that doesn’t respect hooks in WP. You must ask author of that plugin to correct it:(

  549. malyfred 11. 8. 2006 / 12.13

    Andrew da Silva: The only untranslated stuff that I see on your page at the moment is generated by Poll plugin – ask author of that plugin about it.

  550. malyfred 11. 8. 2006 / 12.19

    eduardo:: that’s known WP bug. I’ve suggested fix to the WP developers but it hasn’t been accepted because as they said – there are not supposed to be any tags (html or any other) in the post title…

    Everything should work fine if you use [lang_xxx ] instead of <lang_xxx> tags.

  551. malyfred 11. 8. 2006 / 12.21

    Ruben:: what version of WP do you use?

  552. eduardo 11. 8. 2006 / 21.36

    malyfred: Thanks a lot, that worked like a charm for the page title. Magical!

    Just one thing, and it is sort of a plugin imcompability: When using the ELA plugin, the title in the archives page still shows with both titles, and when using the [] tags even the tags show. You can see the problem here, please take a look down the posts list.
    That seems to be because the ELA plugin creates a cache for its use reading directly from the database, and not using WP’s functions.
    Would you, by any chance, take a look into this? I know this out of the scope of Polyglot, but maybe for the sake of plugin compability…

    Thank you once more!

  553. Andrea 14. 8. 2006 / 15.51

    Hi, I’ve read your post about polyglot plugin and I’m trying to use it in my website. I have to use italian and english languages.
    I have the following problem:
    maybe that a post in italian has not to have a respective post in english. If I gettext only the italian text and I don’t set the text for the second language, in order to do not have this post in the english version, polyglot leaves the text in italian for both the language site version.

    I would like that if a post has to live only in the italian or in the english site version, in the other version it disappear.

    How can obtain this result?

    thank you

  554. Ruben 15. 8. 2006 / 17.43

    Hey Malyfred, I’m using 2.04 currently. Is the installation process for 3 languages different from 2 languages?

  555. tricky 15. 8. 2006 / 23.15

    Malyfed,

    Maybe you can use the Button Snap Class by Owen Winkler to wrap the lang tags around text. I see a lot of potential on your plugin. Have you thought about improving the write post window and providing double entry/excerpt/title? so it automatically gets posted with the lang tags. I’m so happy about your script and the way it works.

  556. tricky 15. 8. 2006 / 23.16

    here’s the link to the button snap class: http://redalt.com/wiki/Buttonsnap

  557. tricky 16. 8. 2006 / 4.46

    Malyfed,
    i’ve got a question.
    I have my WP lang set to es_ES so i can have my admin menu in Spanish. I just had to upload es_ES on my languages directory and update wp-conig-php. I installed your plugin and i was able to setup the language selector and i can write a post i both languages. Now, i’m trying to make my templates gettexted for english and spanish. So i added this as an example:

    And i added “Data Sheet” to es_ES.po/.mo
    and it works correctly when i loadmy blog, it translates it to spanish. Now, when i select english on the lang selector, i see the post content in english (which i wrote inside the tags) but i still see in spanish. I tried uploading a en.po/.mo file, that has the english text in both the original and translated fields.

    Is there any way to keep gettexted template text while having WP using another language for the admin panel?

  558. tricky 16. 8. 2006 / 4.47

    the code i was adding to my template was:

    _e(‘Data Sheet’);

    (it didnt come up on my previous comment)

  559. tricky 16. 8. 2006 / 7.06

    Maybe my previous comments where a bit too confusing. When it comes to post language, it works fine. But when it comes to Categories or gettexted text inside my templates, it only works for the default language, which is Spanish. I created an en.po->en.mo file containing the same entries, but they are still shown in spanish. everywhere where i added spanish, i used “es”, on polyglot.php and the .mo file. And everywhere where i used english, i used “en”, on .mo and polyglot.php i also had to add

    $polyglot_settings[‘wplang’][‘en’] = ‘en’;

    any ideas on how to get _e(“text”) correctly translated on the non default langague?

  560. tricky 16. 8. 2006 / 8.10

    Soooooooooorrrrrry for all my comments.
    but i’ve seem to debug this.
    i’m using wp 2.0.4 and polyglot v2.0beta

    i’m echoing the WPLANG variable on my index.php to see if it changes when i change lang.

    as i wrote before, i have both “en” and “es” as languages, “es” being the default one in both wp-config.php and polyglot.php

    any of the langs i choose, only seem to affect the content of the post between the tags, as WPLANG still echoes “es”.

    i’ve trying to take a look at the code you use to define the current WPLANG between line 284 and 305 but i don’t know how to tell what’s wrong.

  561. Olly S 22. 8. 2006 / 10.15

    Hi there, I am trying to set up Polyglot for use on my blog for my restaurant in Beijing called Vineyard Cafe (shameless plug!). I want to do Chinese and English and am using the modified Polyglot file done by solowoo.com

    Unfortunately I keep getting this error when you click the language links:

    Warning: Cannot modify header information – headers already sent by (output started at /home/.helmsley/omstedall/vineyardcafe.cn/wp-content/plugins/polyglot/polyglot.php:1) in /home/.helmsley/omstedall/vineyardcafe.cn/wp-content/plugins/polyglot/polyglot.php on line 143

    Fatal error: Cannot instantiate non-existent class: cachedfilereader in /home/.helmsley/omstedall/vineyardcafe.cn/wp-includes/wp-l10n.php on line 67

    Can anybody help me please?

  562. Cedric 22. 8. 2006 / 10.16

    I’ve got some problems to localize a plugin using the load_plugin_textdomain() function: I placed the .mo file in my plugin directory and uses the _e($text, $domain) however there is no tranlation appearing… do you have any clue ? what am I doing wrong ? I’m following this doc: http://codex.wordpress.org/Writing_a_Plugin#Localizing_Plugins

  563. dtone 22. 8. 2006 / 23.47

    question:

    does this allow people to use the admin (dashboard) in another language, ie Spanish?

    thanks,

    d

  564. Lum 23. 8. 2006 / 16.56

    Hi, I don’t if you did answer to this question. It is possible to have the language list into a dropdown list? Thanks

  565. Christine 23. 8. 2006 / 17.47

    Hi,

    thanks for your plugin! It’s working fine. Just one question: I’m using wordpress as a CMS and therefore using just pages. If I give pages two versions of names (one in german and one in english) with the option, it will show BOTH names in the sidebar, but the right name as title for the page (in the content area). Do you know how to fix this?

    You’ll see the problem on this page:
    http://mmk.f4.fhtw-berlin.de/?page_id=43&lang_view=en
    The title is “Spenden” in german, “Donate” in english, its appearing well in the content area, but both on the sidebar.

    Hope you can help me…
    Thanks,
    Christine

  566. Christine 23. 8. 2006 / 21.30

    Thanks again, I found the solution. Its a call of the function lang_picker_respect_more($peer->post_title);
    in the plugin, which displays the peer pages.

  567. Christine 23. 8. 2006 / 21.50

    Hi again,

    I have another question :-). I’d like to have that if a user choses the english version for a post, this stays the prefered language, so that when he clicks on another page (which is available in english) it is displayed directly in english and not in german. I know that there is the

    if(function_exists('polyglot_list_langs')){
    polyglot_list_langs(false);
    }

    part for the sidebar, but I’d like to have the language option in the article (loop), not in the sidebar. I tried to put the mentioned code in the loop, but it did not work (actually there where two lines of “english version”, strange…).

    Do you know a solution?

    Thanks!
    Christine

  568. dtone 24. 8. 2006 / 19.37

    in what file can you change the header (of the window) to read something different than http://mysite.com/lang-pref/es/ and mysite/lang-pref/en?

    I know it should be simple…

    thanks,

    d

  569. mr.mark 25. 8. 2006 / 15.09

    hey malyfred.
    first i wanna say your polyglot kicks asses. but i cant figure one thing out.
    i am trying to get the gettexed thingy to work, but it wont translate my menu titles. e.g. “Pages” wont translate to “Pagina’s”
    i already added in my sidebar the “ thing and still it only shows the “Pages” title. .mo file is in the correct dir and also the name ‘Pages’ is correctly given in the .mo file.
    can you please give me some help? thnx!

  570. mr.mark 25. 8. 2006 / 15.10

    the thing i mean is i already added the thing. it got deleted somehow. sorry

  571. mr.mark 25. 8. 2006 / 15.11

    anyway, i added the _e(‘Pages’) thing.

  572. tricky 28. 8. 2006 / 4.59

    mr.mark, i think we are having the same problem.

    can you add this maybe on your sidebar and see if the WPLANG variable changes when you change the language:

    it should change with the language you choose in order to get gettext working. It doesn’t for me, but at least you can debug it this way.

  573. mr.mark 30. 8. 2006 / 9.15

    tricky,
    i’m sorry, but what do i have to add to my sidebar? i cant see what you are pointing at. maybe you can send me an email instead. the address will be mark[A]soulcreeper.net.
    thnx a lot.

  574. tricky 30. 8. 2006 / 17.10

    anyone got succefully working the gettexted function? i still cant get the plugin to change WPLANG, even if i can get it to pick between 2 langs when it comes to display the posts and post titles.

    Any other way to get the theme translated?

  575. tricky 30. 8. 2006 / 17.18

    is there any way to “hardcode” lang selection on themes if gettext doesnt work?

    something like:

    if lang = es; then {echo CATEGORIA}
    if lang = en; then {echo CATEGORY}

    ??

  576. mr.mark 31. 8. 2006 / 8.29

    i entered the debug WPLANG echoing to my sidebar in my website but neither could i get that langcode showing up when changing languages.
    isnt there the plugin maker gonna figure something out, please?

  577. Roberto Gorjão 31. 8. 2006 / 18.04

    Hi! Congratulations and many thanks for your plugin!
    I have a problem though: Excerpts appear in feed readers with both languages and with the lang tags. I already have this filter in the polyglot file: add_filter(‘the_excerpt’, ‘lang_picker_respect_more’,1);
    What should I do more?
    Thank you.
    Roberto

  578. tricky 1. 9. 2006 / 7.13

    i don’t know what my problem can be.
    $locale gets set to the right chosen lang, while WPLANG is always stuck to default lang…

  579. tricky 3. 9. 2006 / 9.02

    When i use wp_list_cats, i get the following text:

    Project-Id-Version: WordPress 2.0 es_ES Formal Beta POT-Creation-Date: 2005-10-05 22:49+0200 PO-Revision-Date: 2006-08-16 00:35-0400 Last-Translator: Language-Team: wordpress-es MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Poedit-SourceCharset: utf-8 X-Poedit-KeywordsList: __;_e X-Poedit-Basepath: D:\wordpress-2\wordpress\ X-Poedit-Language: Spanish X-Poedit-Country: SPAIN X-Poedit-SearchPath-0: .

  580. Pedro 3. 9. 2006 / 12.03

    First of all, thanks very much for this most useful plugin, malyfred.

    In my blog I’ve set up one RSS link for each language. However, the lists of blog entries returned by either RSS feed are both equal. I had imagined that the lang_view=xx parameter would be added to the URL of each entry in the RSS feed list of posts.

    The post titles in the RSS feeds are shown in the corresponding language, but the URLs of those posts are the same in both RSS feeds.

    Is there something I should be doing to get the desired behaviour?

    Thanks very much,

  581. David 7. 9. 2006 / 22.38

    Hi!
    Great plugin! Really!
    But… a question… isn’t there a widget for the sidebar widgets? I mean, the one made by Automattic.

    Thanks!

    David

    P.S.: I can connect only from my mobile, so, please, would you kindly answer to my mail? Thanks so much!

  582. David 7. 9. 2006 / 23.10

    Sorry, created it on my own with widget_polyglot_init() and that function name collided with yours… I’ve found your widget this way… Lol, I’m crazy, I know.

    Cheers,
    David

  583. bo 14. 9. 2006 / 3.27

    hey malyfred,

    installed polyglot and it works great. cheers for that. there’s one thing though. i would like to have the flags for the different languages centered next to each other and it’s really bugging me out. i’m no css-expert, but usually i get it right after a few days. not this time… help?
    cheers for that, bo

  584. ludovick 18. 9. 2006 / 13.36

    Hello, I have a strange bug :

    Warning: Cannot modify header information – headers already sent by (output started at /var/www/html/new/wp-content/plugins/polyglot2/polyglot.php:1) in /var/www/html/new/wp-content/plugins/polyglot2/polyglot.php on line 243

    please someone help… ;(

  585. malyfred 19. 9. 2006 / 15.44

    ludovick:: http://codex.wordpress.org/FAQ_Troubleshooting#How_do_I_solve_the_Headers_already_sent_warning_problem.3F
    Your problem is probably caused by UTF BOM which is not supported by your text editor. You can use one of many good editors which are fully supporting UTF – e.g. http://notepad-plus.sourceforge.net/uk/site.htm

  586. Fredrik 25. 9. 2006 / 7.56

    Hi there,
    I am trying to use Polyglot on my 3K2 (K2) theme. It does not perform the way I want to.

    I am new to this…

    1. I cannot get the flags to show up without the dot and also after the post title. I don’t undestand where to put the code as you have addressed this issue earlier.

    2. I have a list of latest entries in my sidebar. When I use in the title, both title as well as the code show up. is that right..?

    A great plugin! Good work!!

  587. rokur 26. 9. 2006 / 11.06

    Hi Fredrik. I had the same problem as you yesterday, also with K2, and managed to solve your first question…

    Put this above the line beginning with “

  588. Lum 26. 9. 2006 / 23.41

    I’ve a few question about Polyglot, I hope someone can help me…

    1. Despite I’ve modified polyglot.php file choosing the various time and date format, they don’t change choosing different languages, they remain in english. If a use a xx_XX .mo file they change (but Poliglot doesn’t work with them), but with a xx.mo file this don’t work. I use EventCalendar3 too, and I noticed also with it.

    2. I can’t manage to get a post/page title in alla my languages. I’ve 4 languages setted, and if I create a post title like title

  589. rokur 27. 9. 2006 / 0.39

    Right, I made a mess there at 587. What I meant to say was: Put this above the line beginning with “The following two sections are for a noteworthy plugin”, appr. line 100

      ', '', '', '');
    lp_other_langs(' ',' ', ' ', ' ', ' ');
    }?>

  590. rokur 27. 9. 2006 / 0.41

    Gee. I’m sorry Fredrik, cannot figure out how to post code as comment here. Will use your contact-page instead.

  591. Lysiane 29. 9. 2006 / 1.01

    Hello, I have been using your plugin with great success on my blog. I haven’t made every element of it really multilingual, though. Would you know how to apply this to the archives links (not the URLs, but just the way the archives can be displayed in the sidebar) so I can have my monthly archives in English, French and German, too ?

    I would appreciate it very much, and thank you in advance.

  592. Eugen 2. 10. 2006 / 18.24

    Hello,
    I have changed the polyglot.php a little so that instead of lists only now creation of drop down lists is possible, too.

    An example and all info can be found in my Blog:

  593. Felix 5. 10. 2006 / 11.45

    Thanks for this great plugin!
    At first I had some trouble with the links to other languages in a post, because the slash between “lang/xx” an the post URI was missing. I don’t know why this happened. Finally I fixed by adding a leading slash in polyglot.php, line 645 where it says “uri_helper= …”.
    Maybe there is another solution for this iussue as it seems to be a specific problem of my blog…

    Another question: If I want to be redirected to the translated version of the index.php instead to single.php, where do have to change and what? So I’d like to change only the excerpt of the post to the other language but stay on the page where I am. Is this understandable? :)

  594. marco 10. 10. 2006 / 17.13

    hi, i just installed your wnderfull plugin and it works fine. on question i do have: i am using text instead of the flags. how can i change the style of the used (or set as main language) language? if i changed the language into english i would like to change the word english as bold font. probably it is realy simple but i need help :) tnx, marco

  595. opio 12. 10. 2006 / 14.11

    hi, i use polyglot (great plugin BTW!!!) and have the title of my pages in two languages like this (without spaces):
    [ lang_pt ] empresa [ /lang_pt ][ lang_en ]company[ /lang_en ]

    i installed the sitemap plugin and, since it uses the title field to generate the sitemap, it is generating sitemaps with the polyglot language tags.

    is there a quick fix to make the sitemap appear in both languages without too much hassle?

  596. amanda 12. 10. 2006 / 18.10

    I’m trying to get polyglot running and I think I’ve sorted most of it out but I am getting an error when I try to switch languages. My blog lives in a directory (called “blog”!), and selecting either available language gives me this URL:

    http://www.example.com/blog/lang-pref/en/

    (it is a dev site so I don’t want to share the URL) and I get a file not found error for that URL.

    Did I miss a step? I added the wp-lang string in my wp-config.php file. I edited polyglot.php.

    Is this an htaccess problem?

  597. copyesfera 14. 10. 2006 / 16.27

    Hello,

    I belive you can give me the following info: Which is the varible that has got the ISO code of the langueage that has been choosen by a visitor?

    I hope you cant understand my particular english :D
    Lots of thanks

  598. Kent 19. 10. 2006 / 7.35

    Hi!

    Just tried to add your polyglot plugin. I posted a test post, and when I try to click the flag to get the second language, I just get this error:

    The requested URL /archives/2006/10/19/test/lang/no/ was not found on this server.

    As you can see, it links to my archives. That can’t be correct, right? What have I done wrong?

    When I look at the url on your flag, it is not to the archives.

    Thx for any help.

  599. Kent 20. 10. 2006 / 7.35

    How about making an installation guide to this plugin? Reading through 600 posts are kinda impossible…

  600. Federico 20. 10. 2006 / 16.49

    Hi,
    I installed and activated Polyglot … but nothing happens. I tried with different themes, ISO files are renamed, but I don´t get it, what exactly are the steps I have to do after activating the plugin? (I am not good in php, but at least I know copy-paste ;)) (I use worpress 2.04).

  601. Pepe 21. 10. 2006 / 22.54

    I’m with you Federico. I can’t get Polyglot to work in my WordPress 2.0.4 blog. When I click to change language, nothing happens. The locale is not changed.

  602. Lum 25. 10. 2006 / 23.11

    I have a strange problem. If I wrote a post in a certain language, which is different from visitor’s selected one, sometimes this post do not shows.
    It happens only with certain post, but I don’t know why.

  603. Tankmiche 26. 10. 2006 / 14.33

    This plugin is just great! I had to work on it a bit to integrate with other plugins and my oermalink structure (I’m gonna post details about it in my blog).

    But.. thank yoooouuuu! Now it’s all ok, and I’ve got two feedburner feeds, one in english, the other in italian.

    ;-) I think it’s the best plugin I’ve ever had

  604. TankMiche\'s blog 26. 10. 2006 / 17.13

    This blog is now fully polyglot…

    Well, what to say, if you have reached my weblog recently, you have certainly noticed a few new things:

    * There are two feed icons, both in italian and in english, with their feedburner’s counters
    ……

  605. brem 26. 10. 2006 / 21.19

    Hi, I’m using polyglot for my bilingual blog (fr/en). It works almost perfectly.

    One of the major bugs I have right now is with the cookie.

    It seems the cookie is set to my browser’s language, but never is set to whatever language I choose thereafter.

    Could you help me find out where the bug is?

    Before I launched my blog, I tested it on another folder and it seemed to be working then.

    brem, puzzled.

  606. malyfred 27. 10. 2006 / 10.12

    brem:: Polyglot works in two “modes” – first, when you are just switching language of particular post (note the flag next to the post title on this web) and second, when you are switching the language settings in general (flags in the sidebar on this web).

    The second mode should set cookie the first one should not.

    The correspondent PHP functions are polyglot_other_langs for the “post mode” and polyglot_list_langs for the global settings.

  607. malyfred 27. 10. 2006 / 10.15

    Lum: Don’t you have <!–more–> in your “not showing” posts? Read http://wiki.fredfred.net/doku.php?id=wordpress:polyglot for more info

  608. jonny 27. 10. 2006 / 16.17

    Has anyone been able to make polyglot work in the 3K2 theme ? Language switching in posts is working fine and the polyglot cookie is set to the right language. But, the rest of the template stays in the language set in the WPLANG variable.

  609. brem 27. 10. 2006 / 16.24

    malyfred: it turns out part (if not all) of my problem is that if I accessed my blog through martinbreton.com, the cookie was set to martinbreton.com. But when I switched language, it set ANOTHER cookie at http://www.martinbreton.com. So depending on the domain (and thus subdomain) name, it was taking fr or en.

    I fixed the problem using… (and I’ll paste the code for any other users facing the same problem:

    .htaccess:

    # BEGIN WordPress

    Options +FollowSymLinks
    RewriteEngine On
    RewriteCond %{HTTP_HOST} ^martinbreton\.com$ [NC]
    RewriteRule ^(.*)$ http://www.martinbreton.com/$1 [R=301,L]
    RewriteBase /
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]

    # END WordPress

    I’m totally not an expert in .htaccess files, so if you see a blatant mistake, tell me please!

    Now, two issues remain (that I can think of):

    sitemap plugin should tell google to parse the site twice, once for each language.

    ping technorati uses only the feed in one language, so the posts are not read in the other. I should be able to tell technorati that there are two feeds when I ping it.

    Any other things I’m forgetting?

    brem

  610. Tankmiche 28. 10. 2006 / 19.21

    Got an idea, I’ll try to ajaxify the whole thing, to get faster results.. but I do not guarantee anything, of course!

  611. josep valls 28. 10. 2006 / 20.24

    it isn’t working for me, in mozilla i always see the blog in english even if i set /lang-pref/es/
    when i open the blog in explorer i get Fatal error: Only variables can be passed by reference in wp\wp-includes\gettext.php on line 66
    my mozilla is in english, my explorer in spanish

  612. josep valls 30. 10. 2006 / 16.51

    the problem with gettext.php on line 66 is something related with the php version and wp versions from 2.0.1, google solved it.
    now i’m having trobule with date and time formats, polyglot is not using the formats i specify
    $polyglot_settings[‘date_format’][‘ct’]
    $polyglot_settings[‘time_format’][‘ct’]

  613. Guy Bouchard 2. 11. 2006 / 17.35

    Very useful plugin.

    How can i get my archive (by month) display in both language? Right now i only get french since my blogue is first (admin) in french. It would be nice for me to get english archive title (month) too.

    I use DD Sitemap generator (http://www.dagondesign.com/articles/sitemap-generator-plugin-for-wordpress/) to get sitemap. I modified the plugin to get page name in french or english (relative to language) but could i do the same thing with a hook in Polyglot?

    Thanks!

  614. pepe 2. 11. 2006 / 18.18

    I finally managed to make Polyglot work in my blog. I had to remove the following two lines from the function load_textdomain() in /wp-includes/wp-l10n.php:

    if (isset($l10n[$domain]))
    return;

    Now, I can change the interface language.

  615. paco 2. 11. 2006 / 23.21

    Is anyone using the K2 theme here ? I can’t get tags to work inside the K2 sidebar modules.

  616. Jose Amaral 3. 11. 2006 / 20.44

    Your plugin is great!

    I’m trying to implement it on my new site.
    It’s a multilingual blog that I’m writing in 6 languages.

    Am having trouble in customizing.

    Could you please inform where I can get more detailed instructions.

    Thanks

    Jose Amaral

  617. Jean-Marc 5. 11. 2006 / 15.03

    Hi Malyfred,

    Everything is working fine on my web site except categories names in the archive page.

    It’s written :
    Archives de la catégorie ‘ unclassed’
    but it must be :
    Archives de la catégorie ‘Non classé’

    You can see that the title is written in all languages with tags.

    In the archive.php is written :

    What do I need to do to have categories archives right written ?

    Thanks for that big and good job,

    Jean-Marc

  618. Jamaral 5. 11. 2006 / 15.04

    Dear Malyfred,

    Thanks for your Polyglot plugin.

    Am starting a multilingual blog in 6 languages.
    As a beginner in PHP, am having difficulties in setting up the site to offer visitors the option for English, French, German, Italian and Portuguese.

    Please take a look at my blog:
    ( http://www.dujan.com.br/agendons/ )

    On my sidebar, the languages are displayed as follows:
    english, française, deutsch, pt, italiano and es.
    Above the header, the name polyglot has been added!?

    Have already defined the six languages in polyglot.php.

    Now, would like to fix the installation, to
    show:

    ..Languages on the sidebar, as a vertical list;

    .. If possible, would customize size and style of the fonts on the sidebar.

    Could you please help me to fix this?

    I thank you, in advance, for your kind attention.

    Jamaral

  619. Jean-Marc 5. 11. 2006 / 15.20

    Sorry but in the precedent post is not everything written.
    I try to rewrite my message :

    Hi Malyfred,

    Everything is working fine on my web site except categories names in the archive page.

    It’s written :
    [quote]Archives de la catégorie ‘ unclassed'[/quote]

    but it must be :
    [quote]Archives de la catégorie ‘Non classé’[/quote]

    You can see that the title is written in all languages with tags.

    In the archive.php is written :

    [quote]

    [/quote]

    What do I need to do to have categories archives correctly written ?

    Thanks for that big and good job,

    Jean-Marc

  620. Jean-Marc 5. 11. 2006 / 15.21

    Sorry, I’m not able to write part of code and part of the result from my web site.
    How to do ?

  621. Jean-Marc 6. 11. 2006 / 4.49

    Last try to let you see what’s my problem.

    I wrote my message again and add a spaces in tag sigle.

    Message is :

    Hi Malyfred,

    Everything is working fine on my web site except categories names in the archive page.

    It’s written :
    Archives de la catégorie ‘[ lang_fr ]Non classé[ /lang_fr ] [ lang_nl ]niet ingedeeld[ /lang_nl ] [ lang_en ]unclassed[ /lang_en ]’

    but it must be :
    Archives de la catégorie ‘Non classé’

    You can see that the title is written in all languages with tags.

    In the archive.php is written :

    What do I need to do to have categories archives correctly written ?

    Thanks for that big and good job,

    Jean-Marc

  622. Alex 9. 11. 2006 / 18.04

    Hi malyfred,
    I use WP 2.04 and when I activate this plugin i get a white page with those letters displayed: 

    Sometimes those letters are displayed below the editor when i write or modify a post.

    Also when i save a post, i get a completely white page.

    Everything is normal when i deactivate polyglot. Any ideas on that?

  623. josep valls 11. 11. 2006 / 21.14

    en
    i’m desperate to make your plugin work. it seems that most of wordpress functions fail when anything with html entities. i’m trying to start a tri-lingual blog but both catalan and spanish languages have a lot of word with html entities. to start with, the function list_pages failed and left my sidebar blank, i had to hack a lot of code just to have the __() function display properly the “Pàgines” and “Páginas” labels. when it looked like working i tried to activate widgets and then it all broke again and this is to complicated for me.
    anyone have dealed with that and could give me some tips?

    es
    por favor necesito ayuda con el plugin polyglot y el wordpress en general, concretamente los widgets.

  624. jokerine 13. 11. 2006 / 14.28

    I would really like to use your plugin, but it clashes with my admin pages as alex wrote. Please help as this is otherwise a wonderful tool.

  625. josep valls 15. 11. 2006 / 20.12

    Still dealing with po files.
    I’ve noticed I’m having the same trouble as max in the post 535.
    My feed ?feed=rss2&lang_pref=ca is displaying the titles and texts properly un catalan (es-CA) but the language tag is set to en, is there any way to fix it? i can’t find out in the posts.
    en

    btw, Alex, if your pages appear broken, look if there is ANY html entity in your po files, titles, caregories… and remove it because the ampersand symbol & in html entities passed to the internal functions cause wordpress to misbehave.

  626. Alex 16. 11. 2006 / 1.36

    hi josep,

    since my .mo/.po file is german, there are tons of html entities for umlots as ä ö and ü. How do I deal with those?

  627. Ray 17. 11. 2006 / 5.43

    Hello,
    Before I get myself into setting up a new blog, and installing your plugin and learning how it works I want to know how many languages can be configured to run next to each other? I want a site to run 4 languages, with an option to add more. If it is intended to be just dual then just tell me and i wont get into it.
    Cheers,
    -Ray

  628. jokerine 17. 11. 2006 / 17.49

    It works with as many languages as you want. And Josep thanx.

  629. jokerine 18. 11. 2006 / 17.39

    I don’t have any mo files because I run wordpress in english and just want to translate the posts (for now)I removed the & in the theme files didn’t change anything. I suppose the wordpress files themselves will be allright uneditet, because wordpress should work withitself, and the same for all of us.
    J.

  630. Eric 18. 11. 2006 / 23.46

    Hi,

    This is the plugin that would realy like to install but I get the following error:

    Fatal error: Allowed memory size of 8388608 bytes exhausted (tried to allocate 144919 bytes) in /client/home/smead/docs/cidi/blog/wp-includes/streams.php on line 58

    What is using so much memory? please advise,
    Regards,
    Eric

  631. claudio 20. 11. 2006 / 21.32

    Hi. my best compliments for your script!
    I’m tryng to fit it inside a kiwi lite
    canvas theme, without any success…
    I think it would be great for canvas users beein able to use it as well.
    I suck in programming… but it seems easy… (for anyone with a basic knolewdge of php)
    ‘, ”, ”, ”);
    }?>”
    to a canvas block block=(http://support.freshpursuits.com/documentation/show/Blocks)

    I tryed this, without any success:

    ‘, ”, ”, ”);
    }?>

    what i’m doing wrong???

    I wish to port my art/design portfolio from joomla to wordpress wich seems lighter and nicer.Specially using canvas and kiwi lite:)
    Here’s the link for canvas:
    http://www.freshpursuits.com/canvas/

    thanks! ciao

  632. Alex 21. 11. 2006 / 12.36

    Now I did a fresh install of english WP 2.0.5 on a different Server. When I try to (de)activate Polyglot i get this message
    “Warning: Cannot modify header information – headers already sent by (output started at /myserverpath/wp-content/plugins/polyglot.php:1) in /myserverpath/wp-includes/pluggable-functions.php on line 269”

    Any ideat what’s going on?

  633. Cris 22. 11. 2006 / 14.23

    Hi all and Malyfred!

    I am using Ployglot to produce a bi-lingual website English/Italian at http://www.underworld-game.net

    So far, so good.

    I would like to link myself to comments number 474 (stuffMC),497 (rags), 553 (andrea), summarizing my opinions as follows:

    1) We have a way to let visitors post bi-lingual by using tags [ lang_xx ], Okay.

    To my liking it’s somewhat optimistic to assume that a visitor understands that the site is bi-lingual and that (s)he has to use those tags.
    Normally visitors have no time and no will to read and learn.
    This would result in the admin (me) to have to go and edit all the comments to add language tags.

    Solution: I would like to hack Polyglot so that language tags are inserted by default and using the visitor’s preferred language IF no language tags have been placed.
    Is this already on the to-do list? If not, is anybody interested?

    1) There should be some way (option?) to avoid that no-translation-present posts appear.

    In my site most posts are in Italian although the default language is English.

    This gives the english visitors the annoying impression that the site is mostly work-in-progress.

    Solution: here again, I would like to add this option. Anybody interested?

    Finally, all my compliments and everlasting respect for having developed and distributed this wonderful and free tool.

  634. Thomas 25. 11. 2006 / 13.44

    Did anybody made a hack for the “write a post” admin screen so people can choose their language clicking on a button instead of typing

  635. Andre Klaassen 26. 11. 2006 / 1.15

    This is exactly what i need, but I can’t get it to work. I put it in the right directory unpacked but see no flags and adding or shows no languages or flags…. do you have easy proper documentation?

  636. Andre Klaassen 26. 11. 2006 / 1.16

    Yes I did activate it :-)

  637. Alexander Prestmo 26. 11. 2006 / 16.02

    Hey. I really think this plugin is great. After som fiddling it really does what i want. Great :))

    I don’t know if you will be releasing further upgrades of Polyglot, but I have one suggestion to improve it.

    It is quite much work to write the language tags manually and put them around every post you have. How about adding language buttons to the editor so you can mark the text and enclose the tag around it with a button?

    I’m not so good at PHP but I think it could be possible to detect your active languages from ‘knowlangs’ and pull out the name for the buttons from the name set in ‘trans’. The flags could be used for the WYSIWYG editor and pulled out from ‘flags’.

    Now Sawchuck buttons does this so you can edit it for the purpose, but this feature would be great to see in a further upgrade.

    :)

  638. Andrea Micheloni 28. 11. 2006 / 17.27

    I’ve made a sort of integration with the sitemaps plugin for wordpress, you can find it here ;)

  639. joni 28. 11. 2006 / 19.56

    Hi,

    Your plugin has a problem. I can’t have an english version of my blog unless I set WPLANG to ‘en’. mysite/lang-pref/en simply goes back to my default language (fr).

  640. Jesús 29. 11. 2006 / 21.16

    Alex, I have the same problem, but not only (de)activating, also editing the categories.

    Warning: Cannot modify header information – headers already sent by (output started at /home/.bodacious/jesuscarrera/jesuscarrera.info/wp-content/plugins/polyglot2/polyglot.php:1) in /home/.bodacious/jesuscarrera/jesuscarrera.info/wp-includes/pluggable-functions.php on line 269

    Anyone have fixed it?

  641. Alex 30. 11. 2006 / 1.08

    Hi Jesus,
    yes, the solution is already on this page, look for comment 117, 172 and 585. I used notepad+ to edit the polyglot.php and it worked.

    BUT, i have still the problem with white pages on a different server. So it works on one server and i have white pages (the blog, the admin pages, everything) on another server.

    I guess it’s some apache option? Any hints?

  642. dams 6. 12. 2006 / 12.38

    Hi! And thanks a lot for your plugin! Great, my site is quite now in 5 languages! Some improves yet but it works!
    My question is : how can I translate text written in other plugin forms? I’m using also “an other wordpress meta plugin”, “polls” and also “mailing list”, my dream is that I can write also with the the text in the forms of these plugins. how can I do that? thanks for answer

  643. dams 7. 12. 2006 / 13.48

    it seems that the translation don’t work with the function ‘single_cat_title’
    you can see and example in this page :
    http://mazuria.ecolodges.free.fr/?cat=37&lang_pref=fr
    have you already find this pb?
    thanks for answer!

  644. joni 12. 12. 2006 / 10.56

    Just one question,

    Is Polyglot compatible with WordPress 2.1 ?

  645. Sebastian Picklum 13. 12. 2006 / 13.46

    I’ve written a modification that will provide better integration of Polyglot into TinyMCE.

    You can find it here:
    http://www.picklum.net/2006/12/13/polyglot-support-for-wordpress-tinymce/

    Comments are welcome.

  646. r4m 13. 12. 2006 / 20.07

    Hello, thanks fpr the very helpful plugin. I am not finished with experimenting with it. But I am very happy to have it.

    Only one thing: it did not generate xhtml-1.0 strict code in three lines. These are:
    $other_langs .= “&lang_view=$lang'”;
    $other_langs .= “?lang_view=$lang'”;
    $other_langs .= “&lang_view=$lang'”;

    The Problem are the primes(‘) (do you call it “prime” in english?). When I deleted them, everything went fine.

    Thank you.

  647. Jesús 13. 12. 2006 / 20.16

    Thanks Alex, but I was using Scite, a capable UTF8 editor. Oddly I have fixed the problem editing in 8-bit and changing the ñ in español for the HTML code.
    Hope this help someone else.

  648. J4R 14. 12. 2006 / 17.47

    I’m completely newbie to this stuff. I’ve tried to configure the plug in for two languages (catalan and spanish) and although my default one is catalan, the main page always loads spanish texts. Any idea? Thanks in advance!

  649. meju 16. 12. 2006 / 22.45

    Hi.

    Does anyone has valid link to download Language Picker. All links from here and even google leeds to nowhere.
    Can anyone publish it someware?
    thanks in advance

  650. bo 16. 12. 2006 / 23.58

    hey,

    i have a question. i would like only the german rss-feed to appear when german is selected and the same for my english feed. so, how would i do that?
    thanks,
    bo

  651. MacKozer 18. 12. 2006 / 14.17

    I am trying to install Polyglot into K2 theme, but after activation of the plugin I have a message on the screen above the admin panel:

    Warning: array_values() [function.array-values]: The argument should be an array in /home/carlow/ftp/mackozer/wp-content/themes/k2/options/app/sbm.php on line 468

    line 468 is like that: $tmp_modules = array_values($k2sbm_active_modules);

    Best regards

  652. Marcel 19. 12. 2006 / 15.50

    I installed polyglot and created some posts in various languages. The only problem is that if I use the lp_other_langs() function, and I click on the resulting links I get the specific post (in the correct language) but in the “category” kind of display (just the plain post!), and it’s not shown in the main page with the sidebar.

    Any ideas?

    Marcel

  653. meju 21. 12. 2006 / 20.05

    Hello again

    How should looks this line if i want flags next to, not one under another.

    ‘, ”, ”, ”);
    }?>

    thx in advance for help

  654. meju 21. 12. 2006 / 20.07

    Hello again

    How should looks this line if i want flags next to, not one under another.

    ', '', '', '');
    }?>

    thx in advance

  655. meju 21. 12. 2006 / 20.11

    Give up :)

    This part with on the top this site
    if(function_exists(‘lp_other_langs’)) {

  656. Ein Hauch von Ewigkeit - Langauer.net 27. 12. 2006 / 20.07

    Still in cold Germany?…

    I can’t figure it out… the Polyglot-Plugin is running nearly correct (finally!), but Firefox takes English for default now and IE7 chooses German as default language… If anybody has an idea, please comment, thanks! (comment means &#8…

  657. bo 29. 12. 2006 / 21.02

    hey,

    that probably means that you have different default languages set in ff and ie. you can set it probably in options or internet options or something like that.

  658. Roberto Bellina 11. 1. 2007 / 16.19

    Hi, I’m newbie with the wordpress thing. However, after configuring it on my local machine, I tried to configure this multilingual feature. I would like to have en-de-fr-it-es as flags for my WP2 interface…not the single posts localization…
    I downloaded all the .mo files I am interested in; however I don’t understand the way I have to configure the template files of my theme to work as expected…is there a tutorial for this?
    I went through all the comments here…but no way…Please help!

    Thank you

  659. Sale 12. 1. 2007 / 11.45

    Hi all!!
    I’m using this plugin on my website, and I have a question: is there a way to get parmalinks in different languages?

    Let me explain: suppose i wrote a post titled

    Hello

    Is there a way to get http://www.salatti.net/hello on the English version of the blog and http://www.salatti.net/ciao on the Italian one?

    TIA

  660. joni 13. 1. 2007 / 15.41

    DOES THIS PLUGIN WORK WITH WORDPRESS 2.1 ?

    THANX

  661. Sea Jackal 18. 1. 2007 / 9.59

    Great, it works! (i am using WP 2.0.6).

    Instructions are clear but it would be better if you say that you must define define(‘WPLANG’, ‘en’) in wp-conf.
    Setting other language such as define(‘WPLANG’, ‘es’) will not work propertly (template would not change).
    Same as comment 639.

    Thanks a lot.

  662. rom 18. 1. 2007 / 12.42

    Great plugin

    Only one ask because i can’t find the solution, i want to use the plugin to put entry in a lot of language.
    But i ve a problem.

    For example, i make my default language into english

    I post an entry like this :
    but i don’t want to put it into my default language, however an entry appears with the message Sorry, but this post is not available in English … i want that the post don’t appear.
    Like this if i post a comment in different language but not in the default language, it appears a comment (posted in by …) with nothing into the default language or i wish it appears no comment.

    If someone should help me
    Thanks

  663. Dnote 20. 1. 2007 / 1.00

    The language selection does not seam to work using polyglot_list_langs. This is because by blog does not start at index.php but at the root of my domain. Polyglot adds the prefered language parameter to my url and screws it up:

    http://www.domain.com/lang_pref/en

    which obviously does not exist on my site!!!

  664. Dnote 20. 1. 2007 / 1.37

    In fact it does not work at all. If you enter in the post, WordPress will remove it. Am I suppost to enter in the wordpress editor or in the html editor? Either way, wordpress throws these tags away.

  665. Chris 22. 1. 2007 / 9.20

    I am having the same problem as Dnote I think… my site is at http://www.domain.com/wordpress/ and when I try to change languages from the blog homepage the links to go http://www.domain.com/wordpress/lang-pref... which won’t work. If I could make the language picker link to index.php in such cases (when not viewing ?p=x post), maybe I could get it working… ideas?

  666. brem 23. 1. 2007 / 20.10

    the plug-in seems broken with 2.0.7.
    when I call get_links_list() from php, the link categories aren’t being translated. Is it a hook that isn’t hooked anymore? What should I do?

    Is it fixed in 2.1?

  667. gennaro 25. 1. 2007 / 22.52

    This looks like I great plugin!
    But it does not work any longer for my home page with WordPress 2.1. Seems to work on other pages and on posts, but they changed home page management in vers. 2.1…
    I have not been able to set up the plugin for Preferred language selection. I do have WPLANG = ‘en’ in the conf file, but changing the preferred language dose not have consistent effects.
    Would it be possible to switch to a different template upon changing the language?

  668. maryse 28. 1. 2007 / 20.04

    Hello,
    I’m having trouble with the gettext part. In my sidebar I put something like this:
    php _e(‘Newsletter’); I downloaded the french .po file. I added the translation for Newsletter and then I opened it in poEdit and saved it as .mo. I uploaded this file.
    But nothing happens when I switch the language. Am I missing a step?

    Also, I am using the EventCalendar (http://wpcal.firetree.net/) and the excerpts of the posts I post to this calendar are not translated. When the full text appears, then there is not problem, it works. It’s just the excerpts (if you click on Archive or Activites).

    Thanks for any help.

  669. Sylvain 29. 1. 2007 / 2.55

    Hi,

    I’ve just upgraded to WP 2.1 and the plugin works fine, except for pages. If I click on another language to see only that page in another language, I get:

    “Sorry, no posts matched your criteria.”

    If I change the language of the whole blog first, I can see the page in a different language without any problem. Any idea?

  670. Qian Qin 29. 1. 2007 / 5.16

    Hi,
    I have made some changes to Polyglot so it works with “Google XML Sitemaps”, also fixed some bugs I found. I didn’t want to post the complete files here, so I put them on my website. It would be great if you could include them in your next release.

    Qian

  671. maryse 30. 1. 2007 / 7.35

    Hello, You can forget about the second part of my question, as I have stopped using the EventCalendar. But I am still having trouble with the gettext part mentionned in my first post.

    thanks!

  672. adrian 30. 1. 2007 / 18.59

    hi there,
    iam building a blog ntoo right now but i have a problem.

    When i open the page with mozilla english and espanol are displayed under the language tab but when i switch to IE it doesn’t show them anymore the same in safari on a mac….

    you know why ? any suggestions ?

    thx in advance

  673. adrian 30. 1. 2007 / 19.04

    second question, which just came up.

    as soon as i write letters like ö,ü,ä in the articles of the blog, which are used in german the selections english and espanol dispappear under the language in IE as well as mozilla ?

    u got a solution to that too ?

    thx alot in advance !

    adrian

  674. Milan Tucek 31. 1. 2007 / 12.24

    It is compatible width WordPress 2.1 ? Thanks

  675. Marek Klein 31. 1. 2007 / 13.53

    Bez problemov ho pouzivam aj vo verzii 2.1I use it without problems in WP2.1

  676. adrian 1. 2. 2007 / 17.36

    ok first problem solved it was an issue with the flags…

    but still as soon as i write ñ , ä , ö or ü it doesn’t display the letters and the language selection tabs disappear.

    u know why ?

    regards

  677. mooniv 1. 2. 2007 / 17.54

    thanks for great plugin. What should I do to use the function the_date() to show the right results? Do I have to change the date format?or something else? I dont know what problem with mysite. plz malyfred

  678. Milan Tucek 4. 2. 2007 / 17.33

    TO: Marek Klein 31. 1. 2007 / 13.53, Poradite mi prosim, jak se s timto pluginem naklada? Nejak jsem to nepochopil. Plugin jsem aktivoval, ale jak udelat dvojazycne kategorie a dvojazycny clanky? Dekuji

  679. josep valls 11. 2. 2007 / 20.46

    i’m having some problems commented and i’ll try to solve myself (like the monthly archives not being translated). what about the new version of the plugin you said to correct all these?

  680. josep valls 11. 2. 2007 / 20.52

    i red that some people is having trouble translating the dates and so. you answered that php could only work with english format dates.
    what i put the formatting strings in my POT file, so my date and time prints looks like

    and I used only numbers, not month names

    msgid “F jS, Y”
    msgstr “d/m/Y”

    msgid “F jS, Y”
    msgstr “m-d-Y”

    hope it helps someone with the same problem

  681. Alex 13. 2. 2007 / 3.13

    I just noticed: the funny behaviour also seems to go away if I deactivate Breadcrumbs XT.
    Do you know of a method to have yours and that one live side by side and still be able to use sitewide cookie based lang switching?
    Thank You!

  682. shaun 13. 2. 2007 / 19.10

    We are trying to integrate this into our site’s blog but are having real problems trying to set up posts in different languages. we have set the default language to the users navigation language on our site, but when i try and write a post with the tags, it removes all the text and tags for languages that are not my current navigation language. Any help greatly appreciated

  683. Bruno 15. 2. 2007 / 18.44

    Hi,

    I am trying to put my blog in English and Portuguese with polyglot.

    Almost everything is working nice, excepted when I try to change the language at root page, the server thinks /lang-pref/en/ or /lang-pref/pt/ are folders and returns 404 error.

    Does anyone knows how can I solve my problem?

    Thanks in advance for all.

  684. malyfred 15. 2. 2007 / 18.45

    shaun:: there are no modifications made to the text before it’s saved to the DB therefore the tags and the text must be there. The texts are “filtered” only for “presentation”. Do you use WYSIWYG editor?

  685. Pablo Zinc 17. 2. 2007 / 3.29

    Hi,

    I’ve to thank you for such a wonderful plugin. I’m afraid I’m also having problems with the page titles (I guess I’ll have the same with post titles) in the sidebar tree generated by another plugin (WP-dTree http://www.silpstream.com/blog/).

    I’ve been trying different things, but I’m not an expert on PHP; I’d love to keep on using the WP-dTree plugin, but it shows both languages -i.e. a page named ‘Canciones’ (spanish) and ‘Songs’ (english), appear like ‘CancionesSongs’…

    Otherwise, it works ok. I’ve been trying to find how to fix it for hours, and reading lots of comments, but nothing… Could anyone help me?

    Thanks a lot.

    PS: You can see the bug in this page: http://www.mrzinc.com/canciones/ on the sidebar, under ‘Paginas’ (I’ve not translated everyting yet, just testing)

  686. bo 18. 2. 2007 / 20.33

    hey, had the same problem with a few of the plugins i was using. polyglot provides a function lang_picker_respect_more().

    just use it directly in the plugin files and wrap it around the functions that are responsible for the titles.

    here’s an example from the plug&play google map plugin:

    before:
    $title = addslashes(get_the_title());

    after:
    $title = addslashes(lang_picker_respect_more(get_the_title()));

    might look different in your plugin.
    hope that helps, bo

  687. Luca 19. 2. 2007 / 1.41

    Hello,

    I installed Polyglot 2.0 and WP-Cache 2.1.0. Whenever I enable WP-Cache, languages start changing randomly. If I disable it, everything works again. Unfortunately the load on the webserver is very high without WP-Cache.

    I read above that some people where able to fix this same problem by using a cookie name that starts with “wordpress”, but unfortunately the problem persists.
    If there is anything else that you would like to know about my setup, please let me know. Thanks

  688. Bernhard 19. 2. 2007 / 17.47

    Hi there,

    thanks for this great plugin. I have been searching something like this for days now. Tried several plugins, and yours is definitely the best. Excellent work!

  689. Kim 20. 2. 2007 / 10.21

    Hey, im tryin to get this to work, but im not sure i use the right code for my header file.
    I want to always show the flags for the languages i use, but right now when im using this code in header:
    “‘, ”, ‘ ‘, ‘ ‘);
    }?>”
    So there always will be “in my world” 3 flags on the site, never the less if there have been decided any language ?

    Anyone can help with the right code or setting for this ?

    Best regards

    Kim

  690. Kim 20. 2. 2007 / 10.22

    Whoops, sorry, this is the code

    ‘, ”, ‘ ‘, ‘ ‘);
    }?>

  691. Kim 20. 2. 2007 / 10.23

    Sorry, the code mess up for me, i use the code listed under “Language versions”

  692. dngpng 20. 2. 2007 / 22.40

    Hello, thanks for writing such an awesome plugin. I’m using it now for my blog and have done a little hack to the plugin Extended Live Archive to make it work with Polyglot. It could solve the problem that comment #552 has mentioned before.

  693. Mary 25. 2. 2007 / 17.24

    Hello, just wanted to say ( without any originality ) that your plugin is just perfect !

    I just have one little question for everyone hacking and coding : how do you translate post title ? I’ve read each and every comment but I’m surely idiot since I can’t find the code nor how to do it by myself.

  694. bo 26. 2. 2007 / 0.07

    hey, use in the title field while writing your post ;)

  695. bo 26. 2. 2007 / 0.09

    hey, use in the title field while writing your post ;)

  696. bo 26. 2. 2007 / 0.12

    can’t figure out how to post code here… anyway, just add the language tags in the title bar when you write the post. just like you do for the content

  697. Angi 6. 3. 2007 / 4.18

    Hello! I have installed your plugin and put the language changer in my sidebar after changing all the Text in my template to gettext. But when I click on english, nothing happens! (The Posts are not yet translated, so don’t wonder about that. I mean just the titles of my sidebar features, 1 comment/0 comments… and so on.)
    What could be the reason for that? If i change the language to en in my wp-config.php, it turns on english. :(
    greetz, angi

  698. to.rben 14. 3. 2007 / 22.48

    Hi,
    thanks for the great plugin! What about adding a ‘rel=”nofollow”‘ to the /lang-pref/XX/ links inside the polyglot_list_langs() function?

    I did this for me in order to prevent Google from indexing unnecessary URLs. The articles available in different languages will still be indexed, since they contain extra links (/lang/XX/ instead of /lang-pref/XX).

    Regards,
    Torben

  699. Pepe 14. 3. 2007 / 22.53

    if Polyglot doesn’t work for you then you can try the Language Switcher plugin from http://poplarware.com/languageplugin.html, which is based on Polyglot.

  700. Neriodavid 15. 3. 2007 / 9.40

    The new 2.0 version, function lp_other_langs() seems can’t get the language maintained. That is, the link of the post Title seems doesn’t add the …/lang/xx at the end when you change the language version of a post. However, the strange thing is that the fucntion polyglot_list_langs( true | false ) can make the language maintained, even though,after you switched the language, the links on the page don’t append the “/lang/xx” at the end. Do this achieved via cookies or session status?
    Another interested think I want to know is that how I can make the RSS feed change dynamically according the option of the language? Thanks.

  701. Neriodavid 15. 3. 2007 / 9.44

    Oh, another minor problem I found is that on the Admin’s login page, at at the bottom, the text link of “Back to xxx” is not shown correct language, it is shown the raw text like this “xxxx…”.

    Do anyone have the same problmes as I have?

  702. Neriodavid 15. 3. 2007 / 9.45

    Oh, another minor problem I found is that on the Admin’s login page, at at the bottom, the text link of “Back to xxx” is not shown correct language, it is shown the raw text like this “xxxx…”.

    Does anyone have the same problmes as I have?

  703. Julien Lamarche 18. 3. 2007 / 16.51

    Malyfred,

    In order to make the title multilingual, I added the following instruction.

    add_filter(‘bloginfo’, ‘lang_picker_respect_more’, 1);

    in polyglot.php

    Do you see this as causing potential bugs?

  704. Michael 18. 3. 2007 / 21.49

    Hi Malyfred

    i have just updated to WP 2.1.2 and also polyglot 2. Nothing works…
    Looks as if my htaccess is not OK with permalinks.
    Do you have a sample htaccess for any type of permalinks without the index.php?
    Thank you
    Michael

  705. Pablo Zinc 23. 3. 2007 / 20.59

    Thank you very much, Bo (comment 686); it wasn’t easy, because the wp-tree is complicated, but at last it works!!!

    Sincerely, you make my day :-)

  706. Stargazer 27. 3. 2007 / 13.54

    Thanks a lot for the Plugin. I am using it since quite a time now. As a small update for working with the latest version you should add another filter for the title:

    add_filter(‘wp_title’,’polyglot_filter’,1);

    this should do the trick.

    Stargazer

  707. JR 12. 4. 2007 / 13.45

    Hi,
    Is it possible to use [lang_x] tags outside posts, in example inside template code?

  708. Alex 18. 4. 2007 / 23.24

    Hello, and thanks for your plugin,
    My question would be very simple for you.
    Is it possible to display the Flags and the Label Text? Instaid of only the flag or the text.
    So I would be like this:

    Image-Flag-French : Français
    Image-Flash-English : English

    Thanks for your help

    Alex

  709. Dirk 19. 4. 2007 / 13.58

    JR #707: you can use polyglot_get_lang() to check the current language and then put out specific content inside of template code.

  710. malyfred 19. 4. 2007 / 18.41

    #707+#709:
    … or you can use the polyglot_filter function or it’s shortcuts:


    echo p__("[lang_x]some x text[/lang_x][lang_y]some y text[/lang_y]");

    or even shorter:

    p__e("[lang_x]some x text[/lang_x][lang_y]some y text[/lang_y]");

  711. Alex 20. 4. 2007 / 18.38

    Thank you both for your answer. I’m a little bit lost, I’ve inserted this code :
    echo p__(“[lang_fr]Français[lang_ en]English[/lang_ en]”);

    on line 707 and 709. I don’t think it’s the right way to do it ’cause it’s not working.

    Sorry

    Alex

  712. malyfred 21. 4. 2007 / 9.48

    @711 And what do you get then? This is how I use Polyglot in my templates.

  713. Toure 22. 4. 2007 / 18.53

    Sweet, this is what I have been looking for. However, what about completely setting your blog in two languages; I meant the posts themselves. I would like to have to version of my posts.
    Thanks for any help there.

  714. bo 22. 4. 2007 / 20.57

    hey maylfred,

    single_cat_title doesn’t translate for me. there is this in polyglot.php though:
    add_filter(‘single_cat_title’, ‘polyglot_filter’, 1);

    any idea on how to get this to work? thanks a lot, bo

  715. cee 3. 5. 2007 / 9.38

    Hello,
    Is it possible to have the polyglot_list_langs() function display the other languages, and not the one which is currently selected?

    For example, I am working on a site which will be available in both Chinese & English. I’d like a text link to appear in the header which allows the user to switch to Chinese if English is displayed, and vice-versa. I don’t want to have a button to display English if English is already on.

    Please let me know if this is possible!

    Thanks!

  716. cee 3. 5. 2007 / 9.52

    OK – I managed to fix it myself, with a little CSS hack. I just set the ‘current_language_item’ to display:none in my CSS file. Works for me! :)

  717. Thale 10. 5. 2007 / 14.37

    Any news about permalinks? I would use /en/ for english instead of the original redirect string. Anyone? Thanks by advance (my website is written in french by default).

  718. malyfred 10. 5. 2007 / 23.27

    @thale yes, try version 2.0. Permalinks are now fully supported. I forgot to change the text of the post.

  719. malyfred 10. 5. 2007 / 23.29

    @bo What version of WordPress do you use?

  720. Michael 19. 5. 2007 / 20.43

    Hi malyfred – Thanks for a nice plugin.
    Are there an update for WP2.2 on its way?

  721. Arnoud 20. 5. 2007 / 10.52

    Hi, very nice plugin!
    Only since WordPress 2.2 the title’s in the browser show the [lang] tags instead of just the text.

    How can this be fixed?

  722. malyfred 20. 5. 2007 / 13.45

    @Michael What’s wrong with version 2.2? I’ll test it this week.

  723. malyfred 20. 5. 2007 / 13.46

    @Arnoud There used to be some issues about this in older versions of WP. I have to check what’s new in 2.2.

  724. Sebastian Gerhard 22. 5. 2007 / 19.05

    @721 and other People who have the wordpress title problem (Titel is not parsed correctly) with polyglot:

    add this line of code:

    add_filter(‘wp_title’,’polyglot_filter’,1);

    at around line 181 in polyglot.php

  725. Sebastian 22. 5. 2007 / 19.13

    sorry, typo:

    use this:
    add_filter(‘wp_title’,’polyglot_filter’,1);

  726. alessandro 23. 5. 2007 / 10.20

    Hi, I’ve added a filter for textwidget:

    // ABP: filter if not back-end
    if(strpos($_SERVER[‘REQUEST_URI’], ‘wp-admin’) === false){
    add_filter(‘option_widget_text’, ‘polyglot_filter_array’, 10, 1);
    }

    // Function for array filtering
    /**
    * ABP: filter array values
    */
    function &polyglot_filter_array(&$ar){
    foreach($ar as $k => $v){
    if(is_array($v)){
    $ar[$k] = polyglot_filter_array($v);
    } else {
    $ar[$k] = polyglot_filter($v);
    }
    }
    return $ar;
    }

    Hope it helps.

  727. malyfred 27. 5. 2007 / 10.30

    @alessandro thank you, I’ll add it to the future release.

  728. CyprusGuy 28. 5. 2007 / 13.33

    Hi there,
    I just installed polyglot2.2 working on WordPress 2.1. I still have some problems in figuring ouot how I would do that gettexted thing but I guess I will manage somehow. My biggest difficulty is that I cannot get the flag images shown. I get the list alright but not the images. I’ve put this function on the sidebar

    if(function_exists(‘polyglot_list_langs’)){
    polyglot_list_langs(false);
    }

    and the respective one in the polyglot.php is set to TRUE.
    My blog is on a subdomain named blog.alkisdemetriou.com and the polyglot plugin is on its own directories under the WP Plugin directory named Polyglot2. I changed the respective url in the polyglot .php but I still cannot have the images shown.

    Could anyone give me some tips?
    The same goes for the message when a translation is not existent: It doesn’t show at all.

    I would really appreciate an answer.

    Thanks

  729. Rolf 31. 5. 2007 / 17.33

    This plugin does exactly what I was looking for. However, is it possible to disable the function that automatically detects the visitor’s language? It sounds like a nice option and works fine in IE7, but Firefox doesn’t seem to listen–although I told it to show Dutch content by default, it keeps giving me English text first.

    I already tried playing with the code a bit, but I really have no idea what I’m doing and my actions have had either no effect or broke the script. Could you tell me what to do? I couldn’t find the answer in the 728 comments above here, although I may very well have overseen something.

    Thanks in advance.

  730. malyfred 1. 6. 2007 / 19.52

    @Rolf $polyglot_settings['default_lang'] = 'nl'; should do the trick. Also as soon as you click yourdomain/lang-pref/nl/ ‘nl’ is saved to the cookie and then respected properly.

  731. Alexey Maurov 2. 6. 2007 / 5.39

    Hi, very nice plugin! Thanks.
    >>546This is good if there is only one >>language in the post title, but it will >>show both languages if there are two of >>them.
    I had the same problem. I use wp_title();
    I found a solution to the problem:
    http://trac.wordpress.org/attachment/ticket/3755/general-template.php.diff
    Thanks jhodgdon.

  732. Taeke 3. 6. 2007 / 16.19

    Really nice plugin!
    I’ve got a little problem though. When I try to switch languages on the home page (index.php) I get a “No input file specified” error. All other archives etc work perfectly, what’s the problem here?

  733. malyfred 4. 6. 2007 / 9.48

    @Taeke Hard to say. Could you give me a link? It looks a bit like misconfigured web server.

  734. David 9. 6. 2007 / 19.26

    Hi, after a second try I managed to get your plugin to work on my site. However, I use a redirect url ‘www.redirecturl.com’ that points to my blog ‘www.myblog.com/blog’. Whenever I access my page via the redirect url the translator I put in the sidebar doesn’t work. I.e. it tries to call an url that doesn’t exist ‘www.redirecturl.com/lang_pref/en/’ and thus I get an error. Is there any way to change the url to which the links in the sidebar points? ‘www.myblog.com/blog/lang_pref/en/’ I’m not a developer and I’m lost in this matter. Hopefully you can help me. Thanks in advance.

  735. snautz 9. 6. 2007 / 22.01

    This is my mod of polyglot 2.2
    1. added language info to the permalink, and to the links of mounthly archive
    2. added ability to change language in mounthly archive too
    3. setting text_is_missing_message is working now :)

    You may download it, if you wish at http://snautz.googlepages.com/polyglot-2.2snautz_mod.rar
    :)

  736. Momchil 17. 6. 2007 / 15.33

    Hi,

    I have installed this plugin on my wodpress 2.2 and the visual editor seems to stop wrapping the text when I start with and then write text between these tags. It is quite a bit annoying. Is there some way to fix this and is this Polyglot`s problem or the way WP handles [xx][/xx] tags?
    And another, maybe stupid question: can I have shown in my posts (like in yours ^^) without using html code for the brackets?

  737. malyfred 18. 6. 2007 / 9.25

    @Momchil
    1) Unfortunately the visual editor issue is WP’s issue. Have you tried having [xx] tags on separate lines?

    2) No, the only idea in my mind how to show [xx] in the post text is to use html entities.

  738. Momchil 18. 6. 2007 / 13.25

    1) I have tried:

    [xx]
    text here
    [/xx]

    and when I write the text between the tags, it is not being wrapped.

    2) I have tried adding html code (in the code tab) for the closing bracket as in your post above, but when I click to save it, it is transformed into bracket, weird though. Can you incorporate some kind of escaping \[ for instance for [ and \] for ] ?

  739. malyfred 19. 6. 2007 / 11.08

    @Momchil this conversion of html entities is a problem of WP or actually of wysiwyg editor. Turn it off and everything will be ok.

  740. vi-su 20. 6. 2007 / 8.01

    Automatische Online Übersetzung durch Plugins…

    Viele Seiten werden durch automatische Übersetzungsprogramme von einer Sprache in eine andere übertragen. Die Idee, den Leserkreis dadurch zu erweitern, wird durch die Qualität der Übersetzung getrübt und es wird mit Sicherheit…

  741. arry 21. 6. 2007 / 8.22

    You are assured of compatibility with WordPress 2.2 ? After installation I do not see any adjustments :(

  742. malyfred 24. 6. 2007 / 10.37

    @arry What exactly doesn’t work?

  743. jay 25. 6. 2007 / 13.38

    hey,

    just started using your plugin today and it seems quite awsome but i got a little problem:
    I am using a dropdown plugin and i havent been able to figure out how to also translate the menu titles in there.
    I searched this page but comment #4 wasnt really helpful to me…i’d appreciate further explanation!
    thanks

  744. dr770 26. 6. 2007 / 12.39

    Great plugin! Is it any way to make it compatible with navigo: http://adahas.com/work/navigo/ ?

  745. dr770 26. 6. 2007 / 13.15

    I got it, just calling function polyglot_sanitize_title, for “translating” of navigo output.

  746. pako 26. 6. 2007 / 16.52

    If you add the following lines:

    global $wp_locale;
    $wp_locale->init();

    after the load_default_textdomain(); line, then month names get translated, too.

  747. Martin 27. 6. 2007 / 10.43

    Another thing I find cool about language switching is to have subdomains like this:

    http://en.yoursite.com
    http://es.yoursite.com

    ( Considering we have english & spanish )

    Then it would be just adding an alias in the apache conf:

    ServerAlias en.smartone.es smartone.es

    ( You can check this working on http://www.smartone.es No wordpress just for the example… )

    I will try to implement this with polyglot and write another entry if I can get it to work.

    Then we could implement the function by
    #363 TyskJohan (JUST THE IDEA / DIDN’t tried it actually)

    support for in-URI language selection with subdomains:

    function lang_from_qs ($default=’en’) {

    preg_match(‘/(^\S{2})\./’,$_SERVER[“HTTP_HOST”],$match);
    if (count($match) ) {
    $_GET[‘lp_lang_view’]=$match[1];
    } else {
    $_GET[‘lp_lang_view’]=$default;
    }

    return;
    }

  748. Guy Bouchard 27. 6. 2007 / 21.04

    I have some problem with into my post. I think i have done everything alright but it stay in french when everything else is in english. I prefer not modifying post-template.php to correct this but i need my reader to see everything in their language.

    By the way, your plugin is really really helpful!!

    Thanks!

  749. Andre 30. 6. 2007 / 15.37

    sehr schönes thema danke dafür…

    mfg.andre

  750. Ilya V. Azarov 30. 6. 2007 / 16.31

    I’ve written some hacks for your plugin to make it work on my domains like en.domain.com, ru.domain.com.

    Well, here are some hacks for correct work on such kind of domains.

    Later I’ll post hack for your plugin, but I think they are too simpe :)

  751. Kim 1. 7. 2007 / 16.54

    Thanks so much! You’re obviously very busy doing tech support. Your hard and continued work is appreciated.

  752. Anders 4. 7. 2007 / 10.52

    Hi.

    I have the same problem as amanda in comment 596. Is there a solution for this problem?

  753. had 8. 7. 2007 / 20.51

    it works perfect for me.. 10x..

  754. Pierre 12. 7. 2007 / 9.39

    Hi- Thanks for the pluggin, it’s great.
    There is however something I cannot explain or understand.

    If I use:
    if(function_exists(‘polyglot_list_langs’)){
    polyglot_list_langs(false);
    }
    to define the language by default for the blog, it redirects to
    http://www.website.comlang-pref/xx/ instead of
    http://www.website.com/?lang-pref/xx/

    The work around I found was to define ‘hard’ links pointing to …/?lang-pref/xx/

    However there is a problem on some of the pages.
    If you go to my site and choose English as the default language, all the pages show perfectly fine.

    If you choose Espanol or Francais, The font gets much bigger for no obvious reasons only on certain pages.

    For example, if you open the page “A propos de Pierre” (when choosing French as the default language), the text gets incredibly larger but goes back to normal when you go to another page.

    Anybody has any idea why?

    Thanks in advance. Much appreciated.

    Pierre

  755. Raffa 12. 7. 2007 / 17.27

    Hi! I have some problems in making the date of the posts show in different languages. Everything is set alright, but the language of the_date, the “Posted in” and “1(2…X) comment” are always in English (follow the link on the signature to see my website)

    My best compliments for this plugin. A discussion forum would be however really appreciated (it’d make things easier instead of searching for already-discussed issues with a ctrl-f :)). If help needed, let me know. I’d be happy to host the forum on my web site.

  756. rhwinter 13. 7. 2007 / 1.21

    Hi there!
    I made some changes (small improvements?) to the plugin that I would like to contribute back to you, how can I do that? (contact me via e-mail if you can).

    (BTW, nicely done with this!!!)

  757. Marcelo 19. 7. 2007 / 20.58

    Hi, I´m having exactly the same problem as Pierre on #208 (2). When I click the language, switches correctly, but when I click on any link (to see a post o change section) it returns to english (wich is my browser language).
    I´ve tested my browser with this blog and works fine, it always shows the lang i´ve chosen.
    Php code is in the header, I´ve tried in other files but no good results. Anyone can help me?
    Thanks!..
    Marcelo

  758. Abu 22. 7. 2007 / 12.10

    Hi, I tried following the instruction correctly by downloading the .mo laguage file into wp-includes/laguages/ then i activated the pluging polyglot for language translation.
    I also downloaded the default_gettext.zip theme and try them out but it does not translate anything when i click on a flag.

    I read a lot of the comments but they get me more and more confused. Can somebody give simple explanation of all the files that I need, how and where to put them up to make it work.
    I feel like i’m missing some information, but what is it?
    Thanks

  759. Boriel 22. 7. 2007 / 13.12

    A little suggestion:

    The function polyglot_uri_cleaner should have this:
    $the = wp_specialchars($txt);
    before the return.

    This filter other special chars in the url, and prevent some XSS injection vulnerability (not very probable anyway): try
    http://www.fredfred.net/skriker/index.php/?%20script%20alert%20%22hola%22%20&%20%2Fscript%20=#4301267365246314884

    You should not see an alert pop window coming out of your site.

    An thx! for this plugin! :)

  760. Boriel 22. 7. 2007 / 13.13

    Note: The above comment has been filtered by WordPress. Just try
    http://www.fredfred.net/skriker/index.php/?XXXXX
    where XXX is a javascript alert, for example.

  761. rymo 23. 7. 2007 / 2.00

    Hi I’m trying to figure out how to make bilingual rss. As I understand www/index.php?feed=rss2&lp_lang_view=pl should give me polish version but neither i give lang view..or not…i always have english version(which is default).
    I tried netvibes and some plugin to firefox.

  762. Pierre 23. 7. 2007 / 5.02

    Marcelo,
    I solved this problem but I don’t really remember how.
    I think i has something to do with the way WordPress refers to the posts (permalinks). My parmalinks were the default …?## format and i did not work.

    Now, I refer to the posts/pages with the slug name and it works fine.
    I hope it helps.

    For the font size changing, the problem was that the opening tags where after a tag.
    I moved the
    before the tag and everything works fine now.

    Thanks for the great pluggin.

    Marcelo, I hope this helps.

  763. Jib 28. 7. 2007 / 13.14

    Hello Fred !

    Polyglot is really really great.
    As we use it on our business blog (freshfromthehive.eu) and my personnal one I merged Maira’s default theme with the last version of Kubrick (so you have sidebar…).
    And also made the french translation.

    You can find the files here: http://www.freshfromthehive.eu/2007/07/28/wordpress-polyglot-kubrick-16-francais/

    See you, bye.
    Jean-Baptiste.

  764. Kenji 28. 7. 2007 / 20.56

    Hi,

    Thanks so much for this great plugin.

    I noticed that the “read more” (when using a command in the post) links are not modified to include the correct lang parameter. Any idea how this could be done ?

    Also I have a hard time getting google to index the translated articles, is it due to the permalink format (example.com/articles/20070723-title.html/lang/en/ should be example.com/articles/20070723-title/lang/en/ or perhaps like this example.com/lang/en/articles/20070723-title.html)
    Is it possible to add a filter to get_permalink to solve all these problems ?

    Thanks.

  765. Kenji 28. 7. 2007 / 21.02

    Oups : when using a command in the post ===>> when using a ‘more’ command in the post.

  766. malyfred 29. 7. 2007 / 20.20

    @Kejni: the “more” improvement sounds like a good idea – I’ve added it to ma ToDo list.

    The first issue is a big problem. WP’s url handling mechanism is still a bit quirky and I haven’t much success when playing with it:( so I’m bypassing it in current version of Polyglot. Maybe in the future.

  767. Cyphris 30. 7. 2007 / 13.29

    Is there a way to use Get-a-Post AND gengo?
    if you get a post with get-a-post then get-a-post can’t recognise the language or the ID of the post.

    Get-a-Post will always take the latest post even if it’s a translation of the primary post.

    Is there a way around this?, how can you make so that get-a-post knows what language the site is currently on AND get the right ID (for the post in every language)?

  768. (v) 31. 7. 2007 / 7.47

    for localization of blogroll categories links in format simply add this modifier function to polyglot.php:
    add_filter(‘link_category’,’polyglot_filter’,1);

    works good with wp_list_bookmarks() for example..

  769. (v) 31. 7. 2007 / 7.48

    for localization of blogroll categories links in [ lang_xx ]…[ /lang_xx ] format simply add this modifier function to polyglot.php:
    add_filter(‘link_category’,’polyglot_filter’,1);

    works good with wp_list_bookmarks() for example..

  770. scooly 2. 8. 2007 / 11.14

    How can I use Polyglot on custom_fields?

  771. Kim 7. 8. 2007 / 2.03

    Hi I’m looking for help using Polyglot with Event Calendar 3 by Firetree. The posts come up fine, but the side widget doesn’t pass the code to polyglot before output, so all the [lang __] tags and both languages present in the sidebar.
    The widget functions are as follows:
    [code]
    function ec3_widget_list($args)
    {
    extract($args);
    $options = get_option(‘ec3_widget_list’);
    echo $before_widget . $before_title;
    ec3_default_string($options[‘title’],’Upcoming Events’);
    echo ec3_default_string($options[‘title’],’Upcoming Events’);
    echo $after_title;
    ec3_get_events($options[‘limit’]);
    echo $after_widget;
    [/code]
    The function that calls the text is the ec3_get_events function, but since there’s no echo I’m not sure what to do.

    If anyone could offer some help if would be much appreciated. I’ve been trying to solve this for a month but haven’t had any luck yet.

    Cheers-

  772. Joaquin 8. 8. 2007 / 9.36

    Hi!
    I would like to know if I can change the header image for each language. I have a header image with text inside (in picture mode) that needs to be replaced when switching languages.

    BTW, amazing plugin!!

  773. Flippress Blog » Blog Archiv » Backend mit Wordpress 9. 8. 2007 / 12.28

    […] 2. Mehrsprachigkeit Da wir gleich von anfang an in Englisch und in Deutsch starten werden, benötigen wir ein mehrsprachiges System. Das Polyglot Plugin scheint nach den Erfahrungen von Christian Strang ideal geeignet zu sein. […]

  774. Daniel 9. 8. 2007 / 22.41

    Hi.

    I’ve just started using the plugin and find it amazing! Right now I only have one problem, and that is the widgets using WordPress 2.2 and K2. Take a look at the two downmost elements in the sidebar. Why does not polyglot understand the language syntax there?

  775. Daniel 9. 8. 2007 / 23.01

    And the link to the site I’m reffering to: http://nyelapiazza.no/wp/ ;)

  776. malyfred 14. 8. 2007 / 13.13

    @Joaquin:


    <?php
    switch(polyglot_get_lang()){
    case "en":
    echo "<img .../>";
    break;

    case "de":
    echo "<img .../>";
    break;

    default:
    echo "<img .../>";
    break;
    }
    ?>

  777. NightAngel 20. 8. 2007 / 5.52

    Hello, I installed this powerful plugin but I have one little problem. Indeed when I receive an email indicating to me that new comment was posted, there are [ lang_xx ] etc… An error at the time of my installation maybe ? A solution ? Thank you very much and sorry for my bad english ;)

  778. malyfred 27. 8. 2007 / 12.19

    @NightAngel This should be fixed easily by adding hooks for e-mail processing.

    Try to add “comment_notification_subject” hook and some other from http://codex.wordpress.org/Plugin_API/Filter_Reference#Administrative_Filters to the polyglot’s list of registered hooks and you’ll see if it helps.

    Let me know what is the right combination of hooks and priorities and I’ll add them to the official release.

  779. deborre 27. 8. 2007 / 16.28

    Hi, was looking for a multilanguage solution for my wordpress based website and just found your great plugin. It seems to work almost perfect for me except one little thing:

    I wanted my navigation to be multi language as well so I just tried to put language tags in ther as well but it is just showing the different translations next to each other now.

    Hope somebody is able to help me with my little Problem and thank you for this great Plugin again.

  780. deborre 27. 8. 2007 / 16.31

    sry I forgot the link… the page is http://www.deborre.net/wp in the top left corner you can see the two translation “_impressum” and “_imprint” next to each other.

    Thanks again

  781. Michael 29. 8. 2007 / 17.57

    Hi guys. I’m really impressed by your plugin. It works perfectly for my German-English blog. I only have one little problem. I recently added social bookmarking “sumit this” buttons to my page.

    Now I want to make something like this for the template file:
    (it should be php code)

    if current language = de then do begin
    [show counter 1]
    end
    else if current language = en then do begin
    [show counter 2]
    end;

    Can anyone tell me which is the right code for the current language check. Plz help me… I really tried to make it work. But I can’t manage to solve the problem…

    Greetings Michael.

  782. Michael 29. 8. 2007 / 18.04

    Well … I tryed to solve it for up to 2 hours and now 5minutes after I posted this I found the answer…

    Here you go:

  783. Michael 29. 8. 2007 / 18.06

    digg_url = ‘WEBSITE_URL’;
    digg_bgcolor = ‘#FFD3A6’;

  784. Michael 29. 8. 2007 / 18.06

    Hm posting source code doesn’t seem to work. I’m sorry.

  785. tholmes 2. 9. 2007 / 16.01

    Hi!

    Thanks for this great plugin!

    I have one problem: I apply tags to the

    Blogname and the
    Blogdescription

    as well and it works great except for the RSS feed. (The polyglot content itself is correctly rendered.)

    Thanks for any help in advance!

  786. Jack 3. 9. 2007 / 22.49

    I have the same old problem, as I can see in some other post… The plugin don’t work with rss… I configured all the plugin for 2 languages but I obtain the rss only in one language…
    I use wordpress 2.2.1 and this could be the reason… I will wait some help, thanks…
    (PS: It’s a great plugin, rss problem a part)

  787. ademers 6. 9. 2007 / 3.35

    Hi, thanks for the great plugin. I’m using it on WordPress 2.2.2 with K2 v096 and am having the same issue as Daniel in comment #774. I would like to have text widgets appear in 2 different languages. I looked at #726, but am not well versed in PHP, so am not sure where to put this code. thanks for your help…

  788. ovidiu 6. 9. 2007 / 14.09

    hello, I was just curious how you would compare your plugin to gengo. I see some comments in this post so you should be aware of it. I am looking for a multilingual plugin solution for wordpress and at a first glance gengo seemed more complicated because I have to change and adapt a lot of the plugins I am currently using… I just need a good comparison between these 2 plugins, maybe a little pro/con list to help people decide what fits their needs better?thx

  789. roberto 7. 9. 2007 / 9.53

    Can i translate the category_descriprtion()? Cause i call this function from the index of my site…butpolyglot translate only the ‘post’ and dosn’t works with _description…….

  790. Andrea 7. 9. 2007 / 15.02

    Hi Malyfred,

    just to let you know that I have installed your plugin on my blog to make it bilingual (English and Italian). Although I had to play a little bit with it I found it very easy to use.

    Thanks!
    Andrea

    PS: I have quoted Polyglot (with link to this page) in one of my posts.

    Great

  791. EQKE 9. 9. 2007 / 20.08

    Great plugin. Thank you!

  792. enamour 10. 9. 2007 / 22.50

    Thanks again for your great plugins.

  793. does 19. 9. 2007 / 15.03

    Does Polyglot work in the new WP 2.3?

  794. kaiser 20. 9. 2007 / 4.18

    Hi,
    @does: yes, it does.

    @maylfred: but there are still some problems.
    1. on my index-site flags are linking to http://web101.cbel.de/josephhaydn/lang-pref/en(or de) … which doesn´t exist at this point.
    2. can´t figure out how to translate category-names, which i use as title.
    3. could you focus on making a summary of the problems and sollution people are posting (about 10 common and 5 special)
    4. could you make as an result of 3. a to-do list on top of this page for the next release? so developers who might need this plug and bring it further doesn´t have to crawl through all 800 comments and can help easier to finish this plugin?

    5. it rocks, but i can´t make use of it at the current stadium and got no other sollution in sight…. thanks for all, but please spread the further development. as far as i was reading (over one hour) there are several people who want to contribute.

  795. Joachim 20. 9. 2007 / 7.29

    that´s what I am looking for! thanks a lot!!

  796. kaiser 23. 9. 2007 / 13.00

    HINT: (for everybody who tries the plugin)

    Try to get the ‘tinymce’-wysiwyg editor and define there in the drop down list the lang_de and lang_en as (for e.g) german and english, so users/authors can more easily create different languages in your wp: maxpower [DOT] ca/
    how-to-add-buttons-
    to-the-wordpress-editor-
    for-your-plugin-theme/2006/10/28/

    greetings

  797. Sébastien 25. 9. 2007 / 14.37

    Hi,
    This huge plugin is really the most compatible multilanguage plugin I saw. Great work !
    But I needed to edit the languages list in a select list. So I made a mod you can download on my website :
    Informatique de France
    I would be proud to help you in this plugin’s programmation.
    See you !

  798. kaiser 1. 10. 2007 / 15.15

    Hi Sebastien,
    your page is in french….

  799. riiil 3. 10. 2007 / 0.21

    Hi,
    thanks for your great plugin!
    Unfortunately I’ve a problem.
    I use the default permalink style ie. …/blog/?p=2
    Language changing works well everywhere except the main page. That is because in that case there is nothing like ?p=2 just the directory …/blog/ and your plugin adds the /lang-pref/xx/ to the URL so finally it looks like: …/blog/lang-pref/xx/
    and that doesn’t work, because the server wants to find a directory like this.
    How can I fix that?
    Can you tell me how have you done it in your site (I mean how have you put index.php into the url)?
    thanks a lot!

  800. delFuego 5. 10. 2007 / 22.11

    I wonder if this plugin is compatible with your IImage Gallery plugin?

    Lets say I have both installed: if I used this for an image title…

    Image

    …would the image title change accordingly to the language chosen?

  801. Abu Yervant 10. 10. 2007 / 17.32

    I had downloaded and installed polyglot2 in my blog. It still in a dev .

    I love it ……., but not without a problem.

    I place polyglot widget on my sidebar, but it keep send me to 404. Something to do with permalink ( I think ).

    I’m a newbie @ this. Tried to work on the code, but ….

    It was a mesh, and I had to refresh my blog with new copy of polyglot. Enlight me please ….

    Thanks

  802. Mark 17. 10. 2007 / 9.49

    Great plugin.

    I used it here:

    http://puppetfestival.dk/

    And it worked like a charm. All content is in english and danish and is switchable. So far so good. Only I didn’t use a localized theme.

    Now I’m working on a new site and this time I’m gonna use a theme, that is using gettext and is in both english and danish. Currently I’m using Mandingo for testing. But I can’t get it to work. My config.php has define(‘WPLANG’, ‘da_DK’) and da_DK.mo in wp-content/languages. I tried (‘WPLANG’, ‘en’), but it didn’t help.

    There is a da_DK.mo file in the theme directory. There’s no en.mo but the default in the theme is english, so I guess that’s ok. Or should I create an english .mo?

    To the best of my knowledge everything is set up correctly in polyglot.php. But it doesn’t work. The theme strings won’t switch to danish. I’ve got it running here:

    http://mark.gazel.dk/

    Is there a step by step “how to” I can follow? What to put i config.php. What should be be in wp-content languages, what should be in the theme folder etc. When I want my site to be in english and dansih. A file by file approach. I’m sure I’ve set up the plugin correctly. Regarding languages codes etc.

    Is it because I’m using WordPress 2.3 and an update is needed?

  803. Gordie 17. 10. 2007 / 14.59

    Hello Cyphris, I wrote a function to use “get-a-post” with gengo.
    In facts, its a new function to add to gengo_extra_functions :

    *******
    // Sponsored by Gordie Lachance
    // Outputs the translation of the post ID.
    function gengoGetAPost($monpost) {
    global $post, $gengo, $wpdb;
    $now = current_time(‘mysql’);
    $where_posts = “WHERE p.post_date language_preference_id);

    $post = $wpdb->get_row(“SELECT p.* FROM $wpdb->posts AS p INNER JOIN $gengo->post2lang_table AS p2l ON p.ID = p2l.post_id INNER JOIN $gengo->post2lang_table AS p3l ON p3l.post_id='”.$monpost.”‘ “.$where_posts.” AND p2l.translation_group=p3l.translation_group AND p2l.language_id IN ($language_ids) LIMIT 1″);

    if (!$post) { // if there is no translation, show the original post

    $where_posts .= ” AND p.id='”.$monpost.”‘”;

    $post = $wpdb->get_row(“SELECT p.* FROM $wpdb->posts AS p “.$where_posts.” LIMIT 1″);

    }
    get_post_custom($post->ID);
    setup_postdata($post);
    }
    **********

  804. malyfred 18. 10. 2007 / 9.31

    @Mark – that’s quite strange because I use the very same configuration on this site and it works smoothly. The latest fully tested version of WP that Polyglot works with is 2.2 but I am not aware of any important changes added to the version 2.3.

  805. Mark 18. 10. 2007 / 19.41

    Could it be that there isn’t an english .mo-file in the theme folder? Is that essential?

  806. Jay 22. 10. 2007 / 22.21

    Hi, quick question, I assume the content has to be UTF-8 right?

    There’s no way for the encoding to be different?

    Thanks!

  807. René 25. 10. 2007 / 1.46

    Does someone know if there’s a Plugin that shows links to related posts to the one currently viewed that works with Polyglot? I am using a Related Posts plugin on my blog, but as you can see there, it doesn’t really coop well with polyglot :-(
    Thanks for creating an awesome plugin, sir!

  808. Donia 29. 10. 2007 / 13.21

    Please, I have wrote a comment some weeks ago but I think it’s still pending for moderation, could you please check?
    Thank you

  809. malyfred 30. 10. 2007 / 19.57

    @Donia I get about 3000 spam comments a day and only about 50 of them are in the moderation queue which I check manually – the rest of them is deleted automatically. I’m sorry if your post was one of them.

    Post your comment again or send me an e-mail.

  810. Donia 31. 10. 2007 / 13.02

    Ok I’ll try to remember what I wrote.

    First problem (or maybe it’s just the way it has to work):
    the main language of my site should be italian. So in the wp_config I used to set wplang to it_IT.
    Since I installed polyglot I had to change this to en_US because the main language of wordpress is english and so there is no en.mo file.
    If I set again the language to it_IT the theme won’t get translated in english.

    This is not a big problem except for the fact that the date in the posts shows months in English and not in italian or french (which is the third language I offer to my visitors).
    Same happens in the control panel in Options – General Options – Date and Time.
    All the admin panel is translated in italian (or french) when I set lang_pref/it but date and months…

    Example:
    The output date when I set lang in english shows:
    Output: 31 October 2007

    When I set it to italian it shows:
    Esempio: 31 October 2007

    This should be:
    Esempio: 31 Ottobre 2007

    Second problem:
    is there a way to make the event calendar work with polyglot?
    This plugin has the localization but it doesn’t communicate with polyglot.

    Anyway, this are not major problems and I thank you a lot for writing such a great plugin…I love it!!!

  811. Daniele 1. 11. 2007 / 14.11

    Hi!
    I’m using this plugin on my blog, but I have a problem: how can I use it to translate categoryes when using the_tags in WP 2.3?

    I have tried something like “echo lang_picker_respect_more( the_tags() );” but it doesn’t work. Same with the tag cloud function.

  812. suika 1. 11. 2007 / 16.42

    Hey there, superb plugin — thanks very much for all your hard work. I have a small question I’m wondering if you could answer, though. When I specify my RSS feed to Japanese, upon clicking the links featured within the Japanese RSS feed on my blog it defaults back to the English page. Is there any way of making these links to the main site featured within the RSS feed automatically default to the language they’re supposed to be when clicked? Many thanks for any advice.

  813. malyfred 1. 11. 2007 / 23.37

    @Daniele Tags are not supported yet – the tag hooks are not documented on codex.wordpress.org so I have to play with WP2.3 a bit to find the right hooks.
    I hope I’ll fix it soon.

  814. malyfred 1. 11. 2007 / 23.43

    @suika Well, it could be done but the idea is that that the user by default gets the language version of certain page in language that best suits language settings in his browser. This works quite well in most cases and one doesn’t have to specify the language version in URL.
    There are quite many rss related hooks in WP so you can enhance the Polyglot in this way.

  815. malyfred 2. 11. 2007 / 0.04

    @Donia Time and Date translations don’t work because PHP lacks a good and reliable support for this. We were discussing this issue here earlier and I have an idea how to fix it – but don’t have enough time to implement it.

    Yes, any plugin can support Polyglot without even knowing anything about Polyglot. In most cases using internal WP filter hooks should be just enough. In some rare cases when it is not enough you can point the author of such a plugin to this page and he can add few lines of PHP code to his plugin to implement the full support of Polyglot.

  816. Manuel 3. 11. 2007 / 0.55

    Hi, thank you for the great plugin, but I have got a little problem!

    I want to have a multilingual sidebar, but I cant work with !

    I am not so familiar with PHP and WordPress so I dont know how to do it…

    Can you help me please?

  817. Xu - L'instant des... 4. 11. 2007 / 2.36

    Hi,

    thanks for this very helpful plugin.

    To have a better SEO, I’ve modified the menu adding this kind of links :

    <a href=”/lang-pref/en/” rel=”alternate” hreflang=”en”>english</a>

    <a href=”/lang-pref/fr/” rel=”alternate” hreflang=”fr”>français</a>

    Search engines shouldn’t cache duplicate content with this !

  818. malyfred 5. 11. 2007 / 16.48

    @XU Thank you. It’ll be in the next release. There also could be <link> elements added to the <head>

  819. doz 6. 11. 2007 / 0.09

    $polyglot_settings[‘use_flags’] is ‘true’ but I don’t see flags! :(

  820. Gavin 7. 11. 2007 / 18.56

    Hi Malyfred & co.

    Your plugin is fantastic. Its amazing to see that open source stuff is so advanced. I have installed it on a test server here:

    http://gavin.doesntexist.org/LivetoLove/

    Got the translations working in a basic way, and understand about the .mo etc. I’m having a problem with comments – they’re not working. Looks like something to do with permalinks, or maybe the linking itself. I’m using wp 2.3.1 and k2 rc3, but the comment problem is also there in kubrick (gettexted) for me. I assume its a simple configuration problem, but i can’t figure it out!

  821. Gavin 7. 11. 2007 / 18.58

    Just to carry on with the above, it looks like its inserting the #respond or #comment, but not attaching a page_id for the tag to operate on.

  822. Schlumpf 8. 11. 2007 / 11.43

    Hi Malifred,

    thank you for this plugin.

    But I have a problem with validation:

    After lang_view=en there is expected only one ‘ instead of ”.

    What could be wrong?

    Ferdi

  823. kink 9. 11. 2007 / 17.48

    Thanks for the plugin. I’ve tried several similar plugins for WordPress but yours is the best one. Thanks for the great work!

  824. Gavin 10. 11. 2007 / 12.10

    further to my above problem with the URL and commenting, i found if i make the custom permalink /index.php/%post_id% the comment links work first time :) thought i’d post back here incase this is of use to anyone

  825. Manele 12. 11. 2007 / 15.00

    thank you for this plugin! i like this plugin because is not overloading the server so much like other similar plugins

  826. bart sullivan 13. 11. 2007 / 11.38

    Awesome script. One question before I go ripping apart code.

    Is there a way to change the bloginfo->name field so that it works ok in WP2.3.1? Currently, it works find for the first page – but any subsequent page I try to display – it shows something like this:
    Contest Rules | site name in english

    The same also happens when WordPress sends an email to users or admins. Always get that full tag.

    Is there anyway around this? Thanks
    Bart

  827. bart sullivan 13. 11. 2007 / 11.40

    oops – looks like tags got removed… what I meant in the above post is that is displays the full syntax for setting a multilingual anything according to the symbols used in polyglot. dont know how to bypass that syntax filter in this comment Im writing.

  828. math 1. 12. 2007 / 22.47

    Hi, and thanks for your work. great plugin. It use to work, but from I change my permalink to a Pretty permalink, when I click on the french flag, nothing happen and the french translation is not showing up. I don’t wanna translate the template but only the post. If someone has an idea, it ll be helpful, thx

  829. doz 8. 12. 2007 / 1.52

    When I use
    if(function_exists(‘polyglot_list_langs’)){
    polyglot_list_langs(true);
    }
    it shows a flag that is not use in any post!
    why?

  830. Martin 18. 12. 2007 / 22.07

    Hi Malyfred,

    I really like this great plugin! Only this plugin made it possible for me to convert my website to WordPress. I love it!

    I noticed that the plugin does not work together with All in One SEO Pack by uberdose. I asked for a solution there and got a solution. Here it is:

    http://wp.uberdose.com/2007/10/02/translations-for-all-in-one-seo-pack/#comment-20765

    Could you please add this to the next release of your great plugin?

    Oh, another request would be that you maybe add the options to a seperate config file to make upgrades of Polyglot more easy.

    Kindest regards,
    Martin

  831. Martin 19. 12. 2007 / 0.05

    Hi Malyfred,

    hm, I found a problem with Polyglot and WPG2 (Gallery2 integration to WordPress). WPG2 removes the trailing slashes from URLs because of rewriting caused 404 issues. I googled and did not found any solution.

    Is it possible to check if there is a trailing slash and if not add it to lang_view and lang_pref variables? Otherwise these links are broken…

    Kindest regards,
    Martin

  832. Martin 19. 12. 2007 / 10.02

    Hi again,

    it seems that there is a solution for All in One SEO Pack and Polyglot without modifying Polyglot. uberdose did some changes in AIOSP. So stay tuned about that.

    Kindest regards,
    Martin

  833. uberdose 19. 12. 2007 / 11.52

    I have released 1.4.3.8 of All in One SEO Pack which is now compatible with Polyglot. Martin tested it and it worked. No need to modify Polyglot. Let me know if there are any issues with it.

  834. Martin 27. 12. 2007 / 5.20

    Hello Malyfred,
    it’s me again.
    I’m afraid that Polyglot has problems with the Tags function of WordPress 2.3.1. It shows the tags on the live page instead of only showing the proper language.
    Just a problem here? Or did I overread a solution?
    Thanks,
    Martin

  835. Denorm 27. 12. 2007 / 16.29

    if you want to use multilingual categories but cannot because the category name field is only 50 characters, login to mysql and try:

    alter table wp_terms modify name varchar(200) not null;

    this will set the category name to 200 characters.. i think you can go up to 255 characters for a varchar field.

  836. Dexter 28. 12. 2007 / 14.40

    Hey, I had some problems making Polyglot sidebar fit the theme I’m using. Fixed it and wrote a little tutorial

    http://www.a2p.it/wordpress/?p=9

  837. Seguelac 4. 1. 2008 / 17.20

    First of thanks a lot for this plugin. Is it possible to use the plugin to translate meta tags such as meta titles, meta keyword and meta description. Or what is there another way to optimize seo in several languages ?
    thanks a lot

  838. Rodrigo Portela 6. 1. 2008 / 15.17

    Thank you for this great plugin I’m already using in a bilingual website and I want to use it in some other multilingual pages, at least on the personal website I’m now preparing.

    Sorry if this has been already explained (just tell me where), but… is it possible to show a different sidebar depending on the language selected with the plugin? I don’t know php well enough, but I though some conditional code could do that. I already have several registered sidebars for my one-sidebar theme, to use each of them according to the user’s language, but the sidebar just doesn’t change whatever I try on the code. I also tried using different themes (only with a different sidebar), but the theme switcher doesn’t seem to work on my WP version anymore, if I’m not doing anything wrong. I hope I can make it possible by using a single theme with a changing sidebar according to some variable on the plugin or something like that. I’ll really need to have different content depending on the selected language. Any help would be welcome…

  839. Sam 7. 1. 2008 / 21.42

    Hi,

    Thanks for this plugins, it’s awesome !
    I can see on your site that your sidebar is translated. How to translate the sidebar to translate the word links or others ? Thanks for your reply.

    Sam

  840. jim 9. 1. 2008 / 17.14

    Thanks a lot.

  841. Cedric 11. 1. 2008 / 12.52

    Hi everyone,

    Thanks for this plugin. I can’t work out the sitemap and the permalinks with polyglot. I read the comments above but I still don’t know how to do ! Do anyone have an idea ?

  842. ademers 11. 1. 2008 / 20.08

    Hi, I’m still looking for help re #787. How do I make text widgets in sidebar appear in multiple languages?
    Thanks…

  843. Cedric 16. 1. 2008 / 11.09

    Any answers to post #841 ? even for payed support ?

  844. malyfred 27. 1. 2008 / 13.16

    @ALL New version of Polyglot has been just released. Should be fully compatible with WordPress 2.3. Some other issues have been fixed as well.

    @Rodrigo Portela

    switch(polyglot_get_lang())
    case 'en':
    //english content
    break;
    case 'es':
    //spanish content
    break;
    }

    @Cedric Send me an e-mail with detailed description of your problem.

  845. g 29. 1. 2008 / 7.34

    Hi, great plugin!
    Got one question: How to show BOTH flags AND text :( It works, and it’s great, but I’d like to show BOTH.

    Also, how can I show them in one line? Because right now it’s shown in two lines.

    Thanks!

  846. g 4. 2. 2008 / 10.56

    #794, did you solve the problem? I’m having the same one, flags (or text) link to http://domain/lang-pref/en
    which doesn’t exist.

  847. Davide 7. 2. 2008 / 12.29

    #795 I hava a problem with post tags: if I write as tags

    Apple, backup, Time Machine

    when I save wordpress show me in the tag box

    Apple, backup, Time Machine, Time MachineApple

    Why?

  848. malyfred 8. 2. 2008 / 16.32

    @Davide that’s a WordPress’ feature. Polyglot has nothing to do with it

  849. Davide 9. 2. 2008 / 18.47

    malyfred….but in this way I can write tag. if I insert post tag inside the polyglot lang tags, wordpress change the order and I can’t add tags for differete lang.
    Why?
    I have to insert a filter?
    Thanks & bye

  850. Matias, 10. 2. 2008 / 0.27

    Hello my name is Matias Casanova And i wanted to now if anyone new if it reduced the SEO exposition in any way.

  851. Matias, 13. 2. 2008 / 4.52

    Thanks for the plug- in it seems to be working fine.

  852. gio 15. 2. 2008 / 12.57

    plugin don’t do paragraph!!! how to make it work correctly?

    thanks

  853. Dan 16. 2. 2008 / 1.41

    I don’t seem to be able to make polyglot 2.4 work for me. I use a WP 2.3.2 theme but need some assistance to implement it.

    Thanks for any input!
    Dan

  854. malyfred 16. 2. 2008 / 15.20

    @Davide you have to add the the tags in this way:

    [lang_en]english_tag_name[/lang_en][lang_de]german_tag_name[/lang_de]

  855. test 19. 2. 2008 / 17.57

    test en

  856. blogged 20. 2. 2008 / 13.40

    “Polyglot” is not compatible with the plugin “Feedwordpress” :(

    When the plugin “Feedworpress” is active, any post previously added by “Feedwordpress” can’t be switched to another language (all languages are displayed at the same time).

    But if you deactive “Feedworpress”, the posts previously added by this plugin can be switched to different languages…

    Tested on a fresh WP install with this both plugins only.

  857. Krold 23. 2. 2008 / 1.00

    Hi, great plugin.
    I’m running it in tests because I’m afraid I don’t have the time to keep writing my posts in more than one language and I’m wondering if someday I give up from polyglot I won’t have too much trouble to clean-up my posts of all these [langXX] in titles, content, categories and so on. Is there any fast and simple way to return to a clean one language blog if I give up making it multi language? Thanks

  858. deletia 27. 2. 2008 / 22.36

    Malyfred, thankyou for your work!
    I have installed your plugin (good!!!).
    The only one problem it’s the same of #794 and #846: flags (or text) link to http://domain/lang-pref/en which doesn’t exist, but exist with directions like this http://domain/?page_id=11/lang-pref/en/

    thank you for your help

  859. malyfred 2. 3. 2008 / 23.24

    @deletia
    just set:
    $polyglot_settings[‘lang_rewrite’] = false;

  860. Chris 14. 3. 2008 / 11.26

    The translation itself seems to work without issues but deeplinks to that page from elsewhere in the site show the language tags.

    http://www.asiplc.com/category/news

    Any idea why?

    If tried using both square and angle brackets. Help!

  861. 網站設計 15. 3. 2008 / 10.01

    感謝分享!!

  862. nlx 18. 3. 2008 / 16.37

    If my site contains a menu using GIF and JS, can do something for me ? Can i fix the menu problem with some other technics and use the plugin for the rest of the site ?

  863. Martin 19. 3. 2008 / 2.04

    Hello all,

    I got a W3C bug in Polyglot: It prints out two ‘ in a href links. To fix do this:

    Polyglot 2.3:
    Line 707: $other_Langs .= “>{$foo}$afters”;
    (Delete the ‘ between ” and >)

    Polyglot 2.4:
    Line 702:
    $other_langs .= ” rel=\”alternate\” hreflang=\”{$lang}\”>{$foo}$afters”;
    (Delete the ‘ between ” and rel)

    Malyfred, maybe you can put this into the next release or maybe into the current release.

    Kindest regards,
    Martin

  864. Markus 19. 3. 2008 / 13.29

    Hello,

    great plugin, as many other people have pointed out. Here’s my question – and I didn’t see it answered yet.

    The widget titles in WP seem to work in one language only. I have tried what I can (which isn’t much admittedly), but is there a way to adjust the titles of the widgets in a particular language?

    Thank you very much,

    Markus

  865. Zirona :: OpenSource Consulting 19. 3. 2008 / 14.27

    Polyglot editor integration in 5 minutes…

    Polyglot is a great WordPress plugin by Martin Chlupac, which allows WordPress users to offer multilanguage versions of virtually any content. (I’m using it on this website, too.)
    Unfortunately, Polyglot lacks a quite important feature: A proper …

  866. Martin 25. 3. 2008 / 16.02

    Hi Malyfred,

    I got a new gettext Default theme online at http://www.sebald.com/computer-internet/wordpress/default-theme-gettext-edition

    Maybe you like to add this to the top of your Polyglot page.

    Kindest regards,
    Martin

  867. Andrés Milleiro 28. 3. 2008 / 19.11

    Hi,

    I think i have a big problem, i have installed an old version of polyglot, where I had to put instead of and now i can’t recognise my posts, one written in gl and others in es. ¿Where I can download an old version of Polyglot?

  868. g 29. 3. 2008 / 11.13

    Martin (#863) thanks for that fix to the code.
    I’ll check if it solves the problem of #846, #858 and #794.

    bye

  869. g 29. 3. 2008 / 11.17

    Continuing my last post, it also seems to be the problem of #598 and 601, just in case someone reads this.

  870. Valwit 30. 3. 2008 / 18.06

    doing what is described #863 completley wracked up my page. leaving ‘ as it is makes everything work fine, W3C is also happy

  871. Valwit 30. 3. 2008 / 19.13

    Meantime I upgraded to 2.5, Polyglot seems to have a problem with tags. Since 2.5 coused me also other problems I rolled back to 2.3.3, so as for now I’d recomend NOT to update to 2.5

  872. random 1. 4. 2008 / 10.10

    Is there any easy way to add an options:

    1. change tags to just [xx][/xx] ?

    2. select post language by just applying /xx to the end of url?
    (it actually works on my site)

    I have done these changes on earlier versions, but with every new one it takes some time to remember all modifications to plugin code :(

    Could this be a feature? e.g. replace lang_ with some kind of variable?

  873. Iliyan Darganov 1. 4. 2008 / 13.50

    I can confirm too that Polyglot 2.4 does not work correctly with WP 2.5. Hope soon there will be an update.

  874. wiredatom 1. 4. 2008 / 20.28

    There’s a problem in WP2.5 with Polyglot 2.4 trying trying to iterate through tags in posts. If there’s no tag associated with a post, Polyglot will throw an error. So I implemented a simple fix at around line 1002’s [code]foreach[/code] statement:

    Change from this:
    foreach($tags as $tag) {
    $tag->name = polyglot_filter($tag->name);
    }

    to this:
    if(!empty($tags)) {
    foreach($tags as $tag) {
    $tag->name = polyglot_filter($tag->name);
    }
    }

    I hope this helps…

  875. malyfred 1. 4. 2008 / 22.18

    @wiredatom – thank you. I’ve added this fix into the version 2.5.

    @Andrés Milleiro – Polyglot is/should be fully backward compatible… can you provide me with some more details?

  876. Chris 2. 4. 2008 / 21.27

    Isn’t there a widget for polyglot?
    I use WP 2.5 and the navigation is made by widgets.

  877. BuKToP 4. 4. 2008 / 14.03

    How can I make it to translate the links in my blogroll also? I am using WP 2.5 and trying to add .
    But nothing happens. The links are showed with the on the index page :(

  878. Charlie 6. 4. 2008 / 22.50

    Hi! Polyglot is a great plugin, and it never put me in trouble until I tried to translate strange things. I have this code, which purpose is to show a list of categories with each one’s description below:

    cat_ID) . ‘” title=”‘ . sprintf(__(“View all posts in %s”), $cat->cat_name) . ‘” ‘ . $rel . ‘>’ . $cat->cat_name.’‘;
    ?>
    category_description; ?>

    Well, WP prints the cat list, but this doesn’t pass Polyglot’s filter. As this is not a standard function, I can’t figure out how to make it pass Polyglot’s filter. What can I do? Thanks in advance.

  879. Charlie 6. 4. 2008 / 22.53

    Oops— sorry for the lack of formatting. Here it goes again:


    <?php
    $categories = get_categories("title_li=&orderby=id&hide_empty=1");
    foreach ((array) $categories as $cat) {
    $cat_link = '<h2><a href="' . get_category_link($cat->cat_ID) . '" title="' . sprintf(__("View all posts in %s"), $cat->cat_name) . '" ' . $rel . '>' . $cat->cat_name.'</a></h2>';
    ?>
    <p><?php echo $cat_link . ' ' . $cat->category_description; ?></p>
    <?php
    }
    ?>
    </div>

  880. Petr 9. 4. 2008 / 11.11

    Zdravim z Hong Kongu,

    Actually, I am now using qTranslate, who’s author claims he was inspired by you.

    So I think there must be some similarities in his and your plugin.

    I got the qTranslate work pretty damn good (in a site with 2 languages, English and Chinese), except for 2 major issues:

    1.) The Google site maps are not being generated for the Chinese language (because it’s not the default).

    2.) I am using a really nice search plugin called Search Unleashed, and again, only the English half of my site is being indexed by this search plugin.

    I suspect that the issue is related to how the language(s) are chosen.

    For example, the author of another plugin called xLanguage suggests a smart method of choosing a default language for search engines ….. Read the details on his site under SEO http://hellosam.net/project/xlanguage/3

    So, I was wondering if your plugin is better in this respect ….. or give you some ideas.

    Diky za pozornost.

  881. Oliv 9. 4. 2008 / 19.53

    Hello,

    I was using google xml site map: http://www.arnebrachhold.de/projects/wordpress-plugins/google-xml-sitemaps-generator/

    And I found a quick and dirty hack to generate a sitemap.xml file that contained both languages of my site.
    so when you download the previous plugin in sitemap.php you should add on line 2176 by duplication 2175 so it looks like this:
    $permalink_with_fr=$permalink.”lang_view=fr”;
    and add the line 2217 by dupicating 2216 while modifying this:
    $this->AddUrl($permalink_with_fr,$this->GetTimestampFromMysql((…

    @+Oliv

  882. Damian 10. 4. 2008 / 6.40

    is there a way to get the “lang_xx”-tags working in the Custom Fields?
    This question was made in the comment 425 but I didn’t find the answer…

  883. Davide 19. 4. 2008 / 12.59

    Does this plugin works with php-markdown? For some reason the flags don’t show up when they’re supposed to. I use this plugin in another blog, no problem, but doen’t wok with the on I am presently building…

  884. Davide 19. 4. 2008 / 13.22

    Forget the previous question, mea culpa, I was just editing the wrong file. By the way, I am integrating the plugin functions in my custom bilingual template; basically, I make use of pages custom fields to get a two-lined menu; in order to parse the custom fields I used the p__() function. Is this the best way to inegrate the plugin function in my template? Or would you suggest using another function/way? Cheers, Davide

  885. Damian 21. 4. 2008 / 23.10

    I have added p__e where I use the custom field to show the correct language…

  886. Costas 22. 4. 2008 / 0.21

    i am using polyglot in my website. in previous wp versions (2.3) it was working perfect. I am using 2.5 and the latest version of polyglot in my website but i cant see the flags.

    Regards,
    Costas

  887. ¿Por qué bloguear en tres idiomas? | Un Argentino en Eslovenia 27. 4. 2008 / 22.04

    […] No quiero olvidarme entonces de dar las gracias a un increíble plugin para WordPress llamado Polyglot, que recomiendo fervorosamente a todos los blogueros […]

  888. 28. 4. 2008 / 9.49

    , , , . , , . , .

  889. iBlogic » Blog Archive » Cómo introducir entradas y comentarios en varios idiomas 30. 4. 2008 / 9.42

    […] blog utiliza la extensión Polyglot para poder meter entradas multilingües (actualmente español e inglés) y así permitir que […]

  890. Freiheitsfreund 3. 5. 2008 / 15.43

    Hi together, first many thanks for the great plugin that I am successfully using for 1 year now!
    Second a little question:
    I would like to offer 2 RSS feeds.

    1. if German version exists then German version if no German version exists then feed the English version
    (what happens now is the placeholder is fed that I wrote to show on the page if there is no matching entry in German!)

    2. a feed that shows only English posts and really no entry is shown if a post does not exist in English.

    I am sure this is possible by configuring some filters? But I would be really happy if someone yould help me to figure it out. I could not find out how yet…

  891. A Mind @ Play 6. 5. 2008 / 17.06

    […] between multilingual plugins as the features and support changed, from Language Picker, through Polyglot, to Language Switcher or WP_Multilingual. Such a migration might involve moving media around, […]

  892. nlx 7. 5. 2008 / 20.07

    i’ve choosed not to use the flags icon (‘false’) but Safari tries to use it anyway (and can’t display it because of autorisation problems it seems…). Is it a bug with Webkit/Safari ?

    I’ve found other ppl with similar problems on the web…

    WP 2.3.3

  893. Roderik 9. 5. 2008 / 5.22

    Any suggestions on how to get the /lang/xx/ to work. I tried to do a mod_rewrite however it didn’t help.

  894. Polyglot search fix — e-magine [archives] 13. 5. 2008 / 15.28

    […] implementing the Polyglot plugin on a WordPress site I was working on, I found a bug related to the search form: the plugin appends […]

  895. Vladiuz 15. 5. 2008 / 8.24

    Hi

    I have a quick fix for rss feeds to be displayed in the correct language:

    add_filter('feed_link', 'polyglot_feed_link', 5, 2);

    # and then, after the init funtioncion:
    function polyglot_feed_link($url, $type) {
    global $polyglot_settings;
    $url .= "?lang-pref=". $polyglot_settings['lang_pref'];
    return $url;
    }

    This will modify rss feed links according to preferred language, so you don’t have to make links in a few languages. Will also give you correct feed links in the section.

  896. La Mansion » Blog Archive » Plugins Wordpress 16. 5. 2008 / 21.38

    […] Polyglot: Versión mejorada de Language Picker que corrige algunos errores y añade la opción de autodetectar el lenguaje del usuario. Permite mostrar distintos textos dependiendo del lenguaje del usuario. […]

  897. Agent Orange 28. 5. 2008 / 22.29

    I’m using this wonderful plugin, and I would like to thank you for developping it ^^

    Anyway, I have a little mini problem.
    When somebody post a comment in his own language, with the tags is defined, it leaves me a blank comment.

    I don’t know why, because it works with the posts (It leaves a message like “Sorry, this post isn’t available in english”), but it doesn’t work for comments.

    I didn’t find any answer and the comments, but I could have missed it.
    Any idea?

  898. Agent Orange 28. 5. 2008 / 23.09

    Eh, I didn’t express me very well :P

    What I mean is that if someone post a comment in french, with the correct tags, but no version in english, someone who doesn’t use a french browser will find a blank comment.

    What I’d like is that it leaves me a message like “Sorry this comments isn’t available in your language” or something.

  899. Mark 29. 5. 2008 / 11.54

    I got a problem here on the frontpage. Try making a mouseover on the flag:

    http://www.puppetfestival.dk/

    The link is:

    http://www.puppetfestival.dklang/en/

    A slash is missing. Don’t know why. It works on the other pages. Could it be because I use a static frontpage?

  900. Donia 2. 6. 2008 / 10.54

    Hi, Thank you again for the faboulous plugin. I just wanted to tell you that the new version of polyglot in wp 2.5.1 logges me out each time I change the language.
    I had to install the previous version.

  901. nlx 3. 6. 2008 / 17.24

    Please it would be highly apreciated that the plugin would be fully tested with Safari.

    (My problem is when you choose not to use flag icons the plugin don’t work properly.)

    Thanks for the work while that :)

  902. Qtranslate, il plugin definitivo per localizzare wordpress | Leonardo Musumeci 5. 6. 2008 / 19.00

    […] ho provati alcuni: Babel, Polyglot, Jlanguage ma in alcuni casi c’erano problemi di layout, in altri invece venivano localizzati […]

  903. Garçon aka Martin Kopta » Blog Archive » links for 2008-06-07 8. 6. 2008 / 1.33

    […] Polyglot | skriker This post is here to introduce the plugin called “Polyglot” – plugin for complete and easy localization of your blog into several languages. (tags: wp plugins languages) […]

  904. csaba 11. 6. 2008 / 15.17

    Hi malyfred,

    Im trouble in Polyglot.
    +It can use the translations well
    -but the flags dont display
    ….
    I have set these below
    $polyglot_settings[‘use_flags’] = true;

    I have a suspicion due to this below
    (polyglot_list_langs is not known)
    … sidebar.php … just ++ shows !!
    ++

    ……………..
    Do you have any idea ?
    Thanks in advance
    Csaba

    PS:WP 2.1 / Polyglot 2.5

  905. csaba 11. 6. 2008 / 15.20

    …. sidebar.php … just ++ shows !!
    ++ if(function_exists(‘polyglot_list_langs’)){
    echo “+++”;
    polyglot_list_langs(true);
    }
    ………..
    the code example was vanished from previous post

  906. Expo Zaragoza: la Generalitat reconoce que el valenciano es catalán… incluso en su propia web en Siempre Juntos | blog 13. 6. 2008 / 19.48

    […] Como podréis apreciar en las fotos más abajo, si no sabes utilizar un plugin de Worpdress (que yo lo he usado y es jodidamente complicado) y te metes a hacer una página multilingüe para […]

  907. Speak for me in English | Speak For Me 17. 6. 2008 / 21.57

    […] komen kon fé pr… ouvrir un compte sous Jabber ?Je suis en train de tester un plugin, Polyglot 2.0 permettant d’écrire des billets en plusieurs langues. Après deux bonnes heures à […]

  908. Martin 23. 6. 2008 / 21.26

    I just upgraded to version 2.5. I still have the problem that I get emails subjects like this when somebody comments my multilanguage pages (and I’m sure also multilanguage posts):

    [Sebald.com] Kommentar: “Sea water aquarium”

    What can I do about that? It really looks ugly. ;-)

    Regards,
    Martin

  909. Martin 23. 6. 2008 / 21.28

    Ah great your blog strips the Polyglot code. ;-)

    It looks like this (without the spaces):

    [Sebald.com] Kommentar: “[ lang_de ]Meerwasseraquarium[ /lang_de ][ lang_en ]Sea water aquarium[ /lang_en ]”

  910. François-Xavier Bodin, Chef de projet Web - AMOa 27. 6. 2008 / 0.27

    […] Oui, comme j’ai fait sur http://www.bewineconnected.com/ avec Polyglot : http://fredfred.net/skriker/index.php/polyglot/ […]

  911. Impressioni di un tecnico» Archivi Blog » Nuovi Plugins per un blog tecnico 1. 7. 2008 / 22.13

    […] Polyglot per l’internazionalizzazione Italiano/inglese […]

  912. AKERSHOEK.COM » Dutch 5. 7. 2008 / 21.42

    […] If you want more information about the plugin I used please have a look on this page: http://fredfred.net/skriker/index.php/polyglot […]

  913. Impressioni di un tecnico» Archivi Blog » Two step further, a half step back 8. 7. 2008 / 21.49

    […] dovuto disinstallare il plugin WP-latex perché non riesco ancora a configurarlo correttamente: polyglot rimane ancora da configurare ma questo non mi preoccupa, perché la sua configurazione richiede […]

  914. Miklas 14. 7. 2008 / 10.20

    Truly a great plugin, which I am very pleased with. I have a tiny problem though. When used with the Last Viewed Post Plugin http://blog.zeitgrund.de/2007/12/08/plugin-last-viewed-posts-english/ the tags show up in the title.

    Any workaround or am I doing something wrong? It works beautifully apart from the little clash.

    Regards Miklas.

    P.S. I’ve also email zeitgrund about it.

  915. Miklas 14. 7. 2008 / 10.26

    by tags I mean the lang_xx tags inside the []

    Miklas.

  916. Multilingual vs Translator Plugins for Wordpress 22. 7. 2008 / 14.47

    […] PolyGlot Plugin Links :: Official […]

  917. Raffa 29. 7. 2008 / 14.43

    Wrong timestamp in comments feed.

    I have noticed this problem on my website, and apparently it is also on this one. The date of the comments is right in the webpage, but if you go to look into the rss feed of the comments (also here: http://fredfred.net/skriker/index.php/polyglot/feed/ ), the time stamp is mismatched (e.g. showing 30 Nov 2009). I guess this has to have something to do with the polyglot plugin.

    Thanks for any help.

  918. Impressioni di un tecnico» Archivi Blog » Bilingual!! 1. 8. 2008 / 0.08

    […] a implementare il bilinguismo, anche se in una forma un po’ rozza: non ho usato il plugin polyglot ma un altro plugin, il Global Translator. Si tratta di un plugin che esegue una traduzione […]

  919. Un traducteur humain pour votre blog : Le Journal du Blog 4. 8. 2008 / 13.57

    […] Polyglot 2.0 […]

  920. Carsten 8. 8. 2008 / 16.15

    Nice software, but I noticed that the new included WordPress gallery function is not 100% supported by polyglot.
    Here you can see the problem: http://www.halle-fotos.de/paulusviertel/drei-auf-eine-streich/lang/en/
    everything works well but the caption becomes not translated.

  921. 282 plugins para WordPress (4ª parte de la L a la Q) | Pichicola.com 18. 8. 2008 / 1.34

    […] Polyglot: Versión mejorada de Language Picker que corrige algunos errores y añade la opción de autodetectar el lenguaje del usuario. Permite mostrar distintos textos dependiendo del lenguaje del usuario. […]

  922. Wordpress Multilingual | Blog von Michael Karl, Webdeveloper 18. 8. 2008 / 5.48

    […] ein WordPress Plugin aufmerksam gemacht. Der Name ist qTranslate. Im Gegensatz zu Plugins, wie z.B. Polyglot oder dem bekannten Language Switcher unterstützt qTranslate alle wichtigen […]

  923. André 29. 8. 2008 / 3.00

    First of all, thanks for this amazing plugin!

    I’ve been having one little problem (don’t know if I’m the only one): Whenever I upgrade WordPress (and do the auto-upgrade of the database) I lose my “multi-language” titles. The posts stay on both languages, but in the titles the tags are deleted and I end up having to retype all the titles in the second language again.

    Am I doing something wrong?

    Polyglot 2.5, WP 2.6.1

    Thanks

  924. Cooperation IWS: Intranet Nomad Web Server » Blog Archive » How to internationalize your sitemap.xml 31. 8. 2008 / 19.29

    […] is a trick to use the following plugins, Google (XML) Sitemaps Generator for WordPress and Polyglot, respectively a wordpress plugin to generate sitemap.xml file for indexation by search engines and […]

  925. MatoSimi 5. 9. 2008 / 15.19

    Hi, I’m using FireStats plugin on my blog and it contains widget in sidebar which displays popular posts. Titles of this list are not processed by polyglot so it displays lang tags. Can you help me how to fix it?

  926. Vlady 11. 9. 2008 / 8.43

    hi, nice plugin, i’ts very usefull for multilanguage site.

  927. Starkilla » Blog Archive » Mehrsprachig 13. 9. 2008 / 2.03

    […] durch eine kleine Flagge an dem Beitrag angezeigt. Möglich wird das alles durch das Plug in Polyglot. Ich hoffe die Sachen werden auch in LiveJournal vernünftig […]

  928. nataliadevalle.com.ar » ocho 13. 9. 2008 / 21.45

    […] el plugin Polyglot para hacer el sitio […]

  929. Roy 14. 9. 2008 / 21.22

    I’ve been using polyglot for a while, and simply like it. However I have some problems with the delight theme for WP2.6. Unfortunately the Polyglot plugin mixes up the theme in the language that is not set by default. Any solutions?

  930. L10n: localisation of WordPress | James Little 15. 9. 2008 / 15.04

    […] also wanted something for the actual content. Polyglot2 can be used to work out the users preferential locale and if that is available, display content in […]

  931. 生日礼物 18. 9. 2008 / 7.47

    so cool.. i will make a muit-luangage website.. copy that..

  932. kingofpunk 19. 9. 2008 / 3.00

    Hi
    Polyglot2 doesn’t play well with wp 2.6.2 post using
    Anyone with that problem ?

  933. kirjoittaessani » Blog Archive » Mehrzüngig 21. 9. 2008 / 14.32

    […] am just trying out the Polyglot2 plugin by Malyfred. 2.31 […]

  934. WordPress is monoglot 2. 10. 2008 / 3.13

    […] Polyglot, xLanguage, qTranslate: todo o conteúdo na tabela posts utilizando marcações; […]

  935. Yoschis Blog » Mehrsprachiges Blog mit Polyglot 3. 10. 2008 / 16.10

    […] Jojo bin ich auf Polyglot aufmerksam […]

  936. Six Ways to Get More Links: Tips for a Niche Blog. : Big Bucks Blogger 4. 10. 2008 / 16.14

    […] Polyglot is a WordPress plugin can help you provide content in a variety of languages, but you need to supply the content in both languages. Unfortunately, writing copy in both English and Swedish is work. Try robo-translation using Word Translation Plugin; it’s free. If free doesn’t work, you can pay for Angsumans’ Översättare Plugg Pro 4.0 Befriaren also known as “Angsuman’s Translator Plugin Pro 4.0 Released”. […]

  937. StuFF mc 13. 10. 2008 / 12.06

    fred: Regarding my comment #474, is it now implemented? How can I? Also, I need a way to hide comments in french to my german visitors. Somehow visitors would need to “say” in which language they usually write comments (since pretty much nobody writes a comment in multiple languages).

  938. Yoschis Blog » Gengo ein besserer Mehrsprachigesblogplugin als Polyglot 22. 10. 2008 / 15.33

    […] seit einiger Zeit habe ich ein mehrsprachiges Blog mit Polyglot […]

  939. queleimporta.com » Blog Archive » Multilanguage WordPress plug-ins 25. 10. 2008 / 23.06

    […] http://www.fredfred.net/skriker/index.php/polyglot […]

  940. Plugin multi-idioma en WordPress | El Blog de Alex Borrás 26. 10. 2008 / 1.39

    […] Polyglot, permite definir varios idiomas, En las las entradas y páginas se escriben los mismos textos encerrados en unos Tags especiales de cada idioma. Tutroial en el Blog de Andrés Milleir […]

  941. Мои плагины для Wordpress 30. 10. 2008 / 16.47

    […] Еще один недавно установленный плагин — Polyglot. С его помощью можно вести блог сразу […]

  942. Más plugin para Wordpress « El Cubanito Web 1. 11. 2008 / 14.20

    […] Polyglot: Versión mejorada de Language Picker que corrige algunos errores y añade la opción de autodetectar el lenguaje del usuario. Permite mostrar distintos textos dependiendo del lenguaje del usuario. […]

  943. Doctor 2. 11. 2008 / 1.43

    Best of the best

  944. stef 30. 11. 2008 / 0.38

    great….thanks

  945. стАрик 3. 12. 2008 / 13.12

    А вы не пробывали зарабатывать в интернете?

  946. Frances 9. 1. 2009 / 18.06

    Hi,

    I’m using WordPress MU and although my posts are translating fine some of my Widget titles are not translating in the sidebar. You can see the tags.

    I have uploaded the following .mo files to 2 areas: wp_includes/languages & wp_content/languages.
    – en.mo
    – fr.mo
    – en_US.mo
    – fr_FR.mo
    With no luck of seeing any change.
    (en.mo & fr.mo are the same as en_US.mo & fr_FR.mo just renamed) The words are not being translated (see the word “Author” it should be “Auteur” in French).

    I have also ajusted the polyglot.php file to:

    $polyglot_settings[‘default_lang’] = ‘en’;

    $polyglot_settings[‘trans’][‘fr’] = ‘français’;
    $polyglot_settings[‘trans’][‘en’] = ‘english’;

    $polyglot_settings[‘knownlangs’] = array(‘en’,’fr’);

    And my wp_config file to:
    define (‘WPLANG’, ‘en’);

    I have tried to gettext my index.php code but it did not work.

    Does anyone have any ideas?

    Here is the link to the test blog I’m trying this out on:
    http://web5.uottawa.ca/ssms/blogs/test/lang-pref/en/

  947. DoZ 16. 1. 2009 / 1.58

    NEXTPAGE syntax has one problem: the numers linked to page’s sections link to the default language version even if you are clicking from a secondary language version.

  948. Mark 18. 1. 2009 / 16.40

    I would like if it was made possible using WordPress’ captions.

    You can translate the caption text but since WordPress uses the [] brackets i.e.:

    [caption id="attachment_#" align="alignleft" width="*" caption="example"][/caption]

    It messes things up. At least if the image is placed between the lang-start and lang-end tags.

    I’ve tried both [] and brackets.

  949. Criss 12. 2. 2009 / 11.28

    Hi all!

    I am using polyglot extensively in my blogs.

    I am not using lang_rewrite and I discovered that the function polyglot_list_langs in some situations (lang_rewrite inactive) creates bad links that lead search engine spiders to 404 not found errors, thus lowering site’s pagerank, I am afraid.

    For instance, the page at this url
    http://www.fantasy-art-wallpaper.com/?lang_pref=it&paged=9

    produces the “flags” links to
    http://www.fantasy-art-wallpaper.com/&paged=9?lang_pref=en

    You can see that the ? and the & are mis-placed.

    I’m trying to fix this, if anybody has found a solution for it, just post here please or e-mail me at cris.leoni@gmail.com

  950. Criss 15. 4. 2009 / 14.22

    I fixed this.

    Download the fix (2.5 A version of the plugin) at:

    http://software.cristianoleoni.com/tiki-index.php

    See wordpress section

  951. Thomas Greve 11. 5. 2009 / 23.02

    What is the difference between Polyglot 2.5 from you and Polyglot 2.5 A from Criss?

    Do you plan to develope future versions of Polyglot?

    Thank you ;-)

  952. indoswiss 16. 5. 2009 / 16.51

    check out polyglot in action here:

    http://www.indoswiss.co.cc and http://www.indoswiss.cjb.net

    soon going to add custom flags!

  953. ChrisWell » Blog Archive » Into The Dark 21. 5. 2009 / 16.59

    […] struggle for a bilingual page (german/english) i was meddling with several plugins, for example PolyGlot, which enables multi-language posts and pages in a wordpress environment. It turned out quite good, […]

  954. webmaster esmuy.com » Blog Archive » Plugins para Wordpress 21. 5. 2009 / 17.30

    […] Polyglot: Versión mejorada de Language Picker que corrige algunos errores y añade la opción de autodetectar el lenguaje del usuario. Permite mostrar distintos textos dependiendo del lenguaje del usuario. […]

  955. Chauderon 26. 5. 2009 / 12.13

    Hello,
    Thanks for the plugin :)
    I’m having trouble making it work on the homepage. From any other page the language selection works, but not when you first load the site or go back to the homepage (with Home link). Please see the link. What could be the problem?
    Thanks!

  956. Chauderon 26. 5. 2009 / 13.09

    LOL, it’s always like that, I’ve struggled with it for hours and now I manage to make it work, after posting my comment ^^
    It was the lang_rewrite option.
    Please delete my comments if it’s possible… :) Thank you

  957. Javier 31. 5. 2009 / 2.05

    Hi,

    is it possible that Polyglot isn’t working properly in the last version of WordPress (2.7.1)?

    Is anyone else having troubles as I do?

    I see a huge message after every post when Polyglot is activated:

    Project-Id-Version: WordPress 2.7.1 es_ES Report-Msgid-Bugs-To: wp-polyglots@lists.automattic.com POT-Creation-Date: 2009-01-12 00:55+0000 PO-Revision-Date: 2009-03-03 12:57+0100 Last-Translator: Maira Belmonte Language-Team: wordpress-es MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Poedit-SourceCharset: utf-8 X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_c X-Poedit-Basepath: ..\.. X-Poedit-Language: Spanish X-Poedit-Country: SPAIN Plural-Forms: nplurals=2; plural=n !=1; X-Poedit-SearchPath-0:

  958. Post » Haga Dinero Online 13. 6. 2009 / 22.48

    […] Polyglot – Malyfred desarrolló este plugin increíblemente bien escrito, sin lo cual no habría podido hacer este blog en idiomas múltiples. […]

  959. Translation and Multilingual WordPress Plugins « Lorelle on WordPress 15. 6. 2009 / 22.17

    […] Polyglot 2.0 helps to make WordPress bilingual. The successor of Language Picker, it support different time and date formats, permalinks, localization of your WordPress blogs, and different languages for posts and Pages. For some tips on using this on WordPress 2.1, see Making WordPress multilingual. […]

  960. Cristina 7. 7. 2009 / 16.40

    Hi,

    simply wonderful widget. I tried over 10 different widgets that seemed soooo much sophisticated and wonderful, but they all crashed with wp 2.8. Polyglot was simple and it worked like a charm! Thanks a lot, you make life easier for many people!

    Cristina

  961. WordPress als CMS: Tipps & Tricks #1 - currentpageitem, currentancestorpage, currentparentpage, currentpageitem, wp-configphp, ABSPATH - Data Travelers-Blog 8. 7. 2009 / 10.59

    […] der in WordPress 2.5 eingeführten Shortcodes und dem Plugin Polyglot kann man recht schnell und einfach seine Einträge und Seiten mehrsprachig […]

  962. Timothep 10. 7. 2009 / 14.00

    Hi guys, fantastic work you did here, I’m fan! One thing I did not find yet: how to display a flag to signify the language that is currently set. Is there a way to do that already or it need to be added?
    Thanks, Timothep

  963. PaBLoX 12. 7. 2009 / 23.15

    Hi! This is exactly what I was looking for! But I’m still having problems with the little flag on each post. Where am I supposed to paste that code?

    And the other thing… How is that you’re supposed to use it on the permalinks? If I write or on the slug it dissappeared.

    Can you give me a hand please?

  964. 5 Lesser Known but Still Powerful Wordpress Plugins 20. 7. 2009 / 16.05

    […] 5. Polyglot An intriguing reminder of the early days of altavista and Babelfish, Polyglot can make use of automatic translators to translate your posts into several different languages, and features an option to automatically display them in whatever language a given user’s browser settings indicate that he or she reads. In addition, users can select a language for themselves to view your entire blog in one of several different tongues. […]

  965. Даниил Семин 22. 7. 2009 / 5.26

    Тема старая конечно , но прочитал с удовольствием :)

  966. Laguna 23. 7. 2009 / 0.30

    Вообще, когда читаешь такое, посещает мысль, а ведь это ж так просто, ну почему я это не смог придумать Респект :)

  967. Bagaimana Membuat Blog dengan Dua Bahasa atau Lebih? 23. 7. 2009 / 17.16

    […] Polyglot oleh Martin Chlupac […]

  968. cinsel ürün 24. 7. 2009 / 15.16

    Polyglot can make use of automatic translators to translate your posts into several different languages, and features an option to automatically display them in whatever language a given user’s browser settings indicate that he or she reads.

  969. fantezi ürün 24. 7. 2009 / 15.17

    Forgot to mention a detail about the previous fix : make sure you add the line global $weekday, $weekday_initial, $weekday_abbrev, $month, $month_abbrev; at the beginning of the file, before the variable definitions! Otherwise it won’t work.

  970. Oloroko » Lista de Plugins para Wordpress 26. 7. 2009 / 0.02

    […] Polyglot: Versión mejorada de Language Picker que corrige algunos errores y añade la opción de autodetectar el lenguaje del usuario. Permite mostrar distintos textos dependiendo del lenguaje del usuario. […]

  971. Rutja76 26. 7. 2009 / 18.24

    Just FYI, I’ve realised that “Canonical URL Redirect” of WordPress (present in the core from 2.3, but the problem started to appear from 2.8) goes into conflict with Polyglot. For instance, it could happen that an URL like

    example.com/post/lang/de

    is redirected by WordPress to example.com/post/

    causing the post not to change language.

    More info on this bug here: http://wordpress.org/support/topic/237126

    A way to fix it is to disable the Canonical URL Redirect, e.g. by installing this plugin:

    http://picometric.blogspot.com/2009/04/wordpress-disable-canonical-url.html

    Cheers,

  972. Вениамин 29. 7. 2009 / 4.36

    На громких заголовках и подобной шумихе можно делать и не такие успехи :)

  973. Мультиязычные сайты на Wordpress. Выбираем сервис контекстной рекламы 31. 7. 2009 / 9.12

    […] к примерам реализации на основе WordPress и плагина Polyglot: 1. Получим код для размещения баннера для выбранных […]

  974. felix 6. 8. 2009 / 0.48

    Hi malyfred,
    is there a way to translate a string that is created by a widget? Like the “Title” for example which you can set with most widgets.

    Cheers,
    Felix

  975. Martin 7. 8. 2009 / 9.31

    I have the same problem as Raffa (comment 917). The timestamps of the comments feed are broken/wrong. The timestamp of every single comment shows a date and time of yesterday. If I deactivate Polyglot everything is fine. Please help!

  976. ¿Por qué bloguear en tres idiomas? — Un Argentino en Eslovenia 8. 8. 2009 / 14.40

    […] No quiero olvidarme entonces de dar las gracias a un increíble plugin para WordPress llamado Polyglot, que recomiendo fervorosamente a todos los blogueros […]

  977. Language Switcher WordPress Plugin - 聚钱庄资讯网 22. 9. 2009 / 15.54

    […] the Language Switcher. It would not work so well without your help! Language Switcher is based on Polyglot, by Martin Chlupac (the flags came from the Polyglot distribution), which was in turn based on […]

  978. Wordpress als CMS und Multilingual : wordpress::hansi 24. 9. 2009 / 20.42

    […] Polyglot von fredfred […]

  979. Yannick 12. 10. 2009 / 7.31

    974, Felix >
    add the following filter in polyglot.php

    add_filter(‘widget_title’, ‘polyglot_filter’,1);

    Otherwise is the development of the plugin stopped?

  980. Sonja 15. 10. 2009 / 17.05

    great plugin, thank you!

  981. MagicJack 23. 10. 2009 / 20.34

    I Love your intro with the funny sign in the forest etc. You need a bit of a laugh before you venture into the world of polygot, thanks for that
    MagicJack

  982. Plugins para Wordpress para usar con blespot.com | Scorts Cd Juarez 26. 10. 2009 / 3.11

    […] Polyglot: Versión mejorada de Language Picker que corrige algunos errores y añade la opción de autodetectar el lenguaje del usuario. Permite mostrar distintos textos dependiendo del lenguaje del usuario. […]

  983. Елена 26. 10. 2009 / 18.51

    Предлагаю дополнительный заработок (подработка). Доход до 50 000 руб. в месяц. Обучение и раздаточный материал бесплатно. 8-916-923-21-08 Елена

  984. Oloroko Blog – Lista de Plugins para Wordpress 10. 11. 2009 / 23.11

    […] Polyglot: Versión mejorada de Language Picker que corrige algunos errores y añade la opción de autodetectar el lenguaje del usuario. Permite mostrar distintos textos dependiendo del lenguaje del usuario. […]

  985. Cómo traducir el contenido de tus posts en WordPress | Kaos Klub 14. 11. 2009 / 15.53

    […] Polyglot: plugin ya viejo, pero efectivo. Traduce según etiquetas […]

  986. Boriel 15. 11. 2009 / 14.32

    A simple tip: to translate the categories in the admin panel just add these line in the polyglot.php file:

    add_filter(‘category_name’, ‘polyglot_filter’, 1);

    The best place is to put it after the others filters (e.g. at line #218).

  987. Boriel 15. 11. 2009 / 14.59

    The above tip (#986) can also be applied to tags with these two lines in the same file:

    add_filter(‘wp_tag_cloud’, ‘polyglot_filter’, 1);
    add_filter(‘term_name’, ‘polyglot_filter’, 1);

  988. WwW.UrbaNicaNo.Net || Tu Web De Reggaetón & Eventos Urbanos » Plugins para Wordpress 30. 11. 2009 / 1.06

    […] Polyglot: Versión mejorada de Language Picker que corrige algunos errores y añade la opción de autodetectar el lenguaje del usuario. Permite mostrar distintos textos dependiendo del lenguaje del usuario. […]

  989. steroids 4. 12. 2009 / 10.32

    ZMsark, did you happen to fix your code so that in Mozilla/Firefox once you enter a quicktag it doesn’t jump to the top? I know that Alex fixed it on his, but just wondering if you had an updated one?

  990. Tutorial para tener un blog en varios idiomas en Wordpress 17. 12. 2009 / 11.43

    […] Como muchos que leéis el blog lo sabéis, este blog se puede leer tanto en Gallego como en Castellano. Todo esto es posible gracias a un plugin para WordPress (WordPress es el CMS, el software que usa este blog) llamado Polyglot. […]

  991. Светлана 17. 12. 2009 / 15.40

    Сдаем помещение под устройство автомойки, автосервиса, склада, отдельно стоящее здание в нем кафе и магазин, САО 8-905-756-40-37 Надежда

  992. Flying Ziggy » Blog Archive » Gettext: Images and Flash 30. 12. 2009 / 17.20

    […] use CSS to change element background images. This gives added flexibility to wordpress plugins like polyglot and language […]

  993. Plugins para Wordpress. | Puydi Publicidad 100% efectiva 5. 1. 2010 / 6.30

    […] Polyglot: Versión mejorada de Language Picker que corrige algunos errores y añade la opción de autodetectar el lenguaje del usuario. Permite mostrar distintos textos dependiendo del lenguaje del usuario. […]

  994. Janneke 8. 1. 2010 / 22.47

    Hey, first of all: the plugin is great!
    I have only one problem: my feed. you said you use two different feeds with feedburner, but it doesn’t work…
    Which adress do I have to enter to feedburner?
    I hope you can help me,
    Janneke

  995. empty pages » Updated plugin Google sitemap with Polyglot support 11. 1. 2010 / 11.52

    […] in order to put in sitemap.xml all localized links to posts, my multilanguge blog based on Polyglot plugin (author Martin […]

  996. Sergey N Lukin (slookin) 11. 1. 2010 / 12.02

    I update latest Google sitemap plugin for support Polyglot
    http://look-in.net/polyglot-sitemap-wordpress

  997. Plugins para Wordpress de la A a la Z. | La Fanega 13. 1. 2010 / 12.05

    […] Polyglot: Versión mejorada de Language Picker que corrige algunos errores y añade la opción de autodetectar el lenguaje del usuario. Permite mostrar distintos textos dependiendo del lenguaje del usuario. […]

  998. Global translator, Basic bilingual et autres plugins pour wordpress en plusieurs langues. | Encre de Lune 19. 1. 2010 / 4.29

    […] en 2005. Et il ne se trouve pas dans les extensions à télécharger sur wordpress.org, mais sur le site de son auteur où on peut voir son […]

  999. Bloguer en plusieurs langues : 10 éléments à prendre en considération | Geek-Presse.net 26. 1. 2010 / 23.48

    […] Polygot 2.0: J’entends beaucoup de bien à propos de ce plugin qui est sûrement le concurrent directe de Wpml. Cependant, il me semble qu’il n’est pas très userfriendly et demande certaines connaissance en PHP alors que Wpml convient mieux au Blogueur lambda. […]

  1000. 10 elements to consider when blogging in different languages | Geek-Presse.net 8. 2. 2010 / 22.46

    […] Polygot 2.0: J’entends beaucoup parler de ce plugin qui est sûrement le concurrent directe de Wpml. Cependant, il me semble qu’il n’est pas très user-friendly et demande certaines connaissance en PHP alors que Wpml peut être utilisé par un Blogueur lambda. […]

  1001. Cindylooia Soup 9. 2. 2010 / 22.19

    Polyglot | skriker…

  1002. Multilanguage support in Wordpress | Blafasel bloggt 26. 2. 2010 / 15.11

    […] Polyglott plugin Dva studenti… […]

  1003. Plugins para Wordpress « 3. 3. 2010 / 1.50

    […] Polyglot: Versión mejorada de Language Picker que corrige algunos errores y añade la opción de autodetectar el lenguaje del usuario. Permite mostrar distintos textos dependiendo del lenguaje del usuario. […]

  1004. Shinnobi 12. 3. 2010 / 13.00

    ^^

  1005. Polyglot | kamille l 20. 3. 2010 / 16.04

    […] looking for a plugin to make my blog ‘bilingual’. Now I’m testing Polyglot. You can choose your language on right sidebar, i’m trying to put choice from a post […]

  1006. Илья 29. 3. 2010 / 21.24

    Сборник книг разного жанра и напрвалений – периодическая литература, газеты, журналы, фантастика, любовные романы, детективы и многое другое

  1007. Ринат 2. 4. 2010 / 22.09

    Дачу продам, ж/д ст.\”73км\” 15 мин.пешком, Горьков. напр-е, 6 соток, 2 дома, баня, бассейн. Вода, свет, лес, подъезд всегда. Собственник. 1,7 млн.руб. Торг.
    ri49@yandex.ru

  1008. adalovelace 8. 4. 2010 / 14.31

    i love your plugin. I just had a little problem with the ‘related posts’ plugin http://fairyfish.net/2007/09/12/wordpress-23-related-posts-plugin/ that leaves the [lang_] tags in the titles of the widget… but is really easy to install.

  1009. istsexshop 10. 4. 2010 / 12.41

    that you put e.g. in your sidebar.php. Function polyglot_list_langs() accepts one optional parameter true or false that says whether names of languages or flags should be shown.

  1010. Polyglot | Salatti.NET 11. 4. 2010 / 19.36

    […] a blog with WordPress, you can easily do the same. How? There is a plug-in for WordPress called Polyglot that you can download and install in your own blog. Polyglot is really easy and fast to set up and […]

  1011. test : Sahaja Samadhi 13. 4. 2010 / 22.08

    […] Polyglot Published: August 11, 2006 Filed Under: Uncategorized Comments are closed. « Previous Post Next Post » […]

  1012. Crèdits « Roger Valls, comunicador freelance 18. 4. 2010 / 23.09

    […] pàgina utilitza addicionalment els plugins Polyglot i […]

  1013. Felix 21. 4. 2010 / 10.56

    Hi there,

    another question (after repeating once more: thanks for the great plugin)

    I use another wordpress plugin (Wordbook) which sends the posts to Facebook. SInce most of my FB friends aren’t German I would like Wordbook to use the content instead of the (standard language of my blog) German

  1014. Felix 22. 4. 2010 / 3.53

    Oh, some content got lost…

    So I have tried to add a filter for the other plugin function add_filter(WORDBOOK_FUNCTION,lang_picker_respect_more,1) [no proper mark-up here].
    But it doesn’t seem to work. Also changing the default language of my blog to EN (which I don’t really want to do) didn’t help.
    Any Ideas?

    Cheers
    Felix

  1015. Felix 23. 4. 2010 / 2.17

    Hello again,
    it is working now, but seemingly because I changed the standard language to EN. As I mentioned I don’t really want to do this, so if you have any other suggestions, I’m happy to hear them!

    Thanks
    Felix

  1016. rwgsdf 25. 5. 2010 / 7.43

    nice !best wishes for you!

  1017. Thomas Greve 6. 6. 2010 / 18.58

    Does Polyglot also support WordPress 3.0?

    Thank you

    Thomas

  1018. 5 plugins para criar um site multi-língua com Wordpress | Templates e Wordpress Themes 22. 6. 2010 / 16.55

    […] Polyglot de Martin Chlupac […]

  1019. Владимир 21. 7. 2010 / 16.28

    Internet сайт http://www.humoranekdot.ru. Большая коллекция анекдотов. Все советские, российские анекдоты, шутки и приколы в одном месте! На сайте нет цензуры и предварительного отбора публикуемых материалов. Самая полная коллекция историй и анекдотов.

Bohužel, komentáře nejsou nyní povoleny.

© 2004 - 2024 malyfred