Viewing 15 replies - 1 through 15 (of 49 total)
  • Hi I have the same problem with site titel and tag line not translating. I’m using WP 3.4.2 (with Pagelines Framework).
    I read another post of someone that had the SEO All-in-One plugin installed and that caused the problem.
    I don’t have that plugin. I’ve got Yoast SEO. Could the problem be similar because it’s also a SEO plugin?

    Thanks for any help.
    Jan

    Thread Starter m.yovkov

    (@myovkov)

    I am using Yoast SEO too. Unfortunately the translation of site title and tag line doesn’t work even if the Yoast SEO is disabled.

    Aha that’s great troubleshooting. Thanks for the info. I hope one of the Polylang devs can shine a light.

    Thread Starter m.yovkov

    (@myovkov)

    It works if I change the theme to “Twenty Eleven”. If I use a theme “Headway Base” it does not work.

    Chouby could you try to shed a light? My framework developer tells me that there framework supports all WordPress translation methods. Not sure if they’re right.

    Plugin Author Chouby

    (@chouby)

    Your framework supports WordPress translations method. It means that the theme can be translated. You canddisplay it in whatever language you want. So every static strings should be correctly translated on your multilingual site.

    If the theme or a plugin uses the standard WordPress function to display the site title and the tagline (as of course themes developed by the WordPress team do!), then Polylang knows that it must translate these strings and so you can translate theme in Settings->Languages->Strings translations.

    However, if the theme or a Plugin uses another way, then Polylang can’t know by itself, so the theme or the plugin must inform Polylang about the string to translate.

    This is done by the functions pll_register_string on admin side and pll__ . There are several examples in the forum on how to adapt themes or plugins (as well as some links in the doc).

    Sorry Chouby, I DID search, but the WordPress Forums are one medieval piece of work when it comes to searching and categorisation.
    Thanks for pointing me to the right post, I will research that and presumably find the solution.

    Thanks!
    Jan

    Plugin Author Chouby

    (@chouby)

    Wow thanks a lot, for the hint about Google and the links, that helps a lot!

    Hi Chouby,

    Wanted to check the following before I have to go fiddle with code. Not an expert at that.

    I got the following response from the Pagelines Frameworks devs:

    We use wp_title() filter and bloginfo( ‘description’ ) as per the wordpress theme standards.

    Have you got an idea why this would not work with Polylang?

    Thanks, Jan

    Plugin Author Chouby

    (@chouby)

    wp_title, bloginfo(‘name’) and bloginfo(‘description’) should be correctly translated by Polylang except if a plugin overwrites what Polylang did before the theme displays.

    And for me, it works with the combination I tested: WordPress SEO + Polylang + Twenty Ten

    Okay good to know. I’ll search further.

    Plugin Author Chouby

    (@chouby)

    Did you try with the simplest multilingual install, Polylang + Twenty Ten and no other plugin ?

    Hi Chouby,

    No not with TwentyTen. I’ve only got Pagelines Framework installed. But I did test with only Polylang and PL Framework. And that didn’t work either, so it can’t be another plugin. I’m not using custom php functions that might override native PL Framework behaviour.
    So the ‘bug’ must probably be somewhere in a compatibility issue. Although PL is rock solid it must still probably be the PL Framework if you say that it works with TwentyTen.

    I’ve contacted the PL Framework devs again with your comment hopefully they can think again!

    Plugin Author Chouby

    (@chouby)

    Ooops… I wrote something wrong. wp_title does return the title of the page displayed, without the site name, so it should not be concerned by our problem here, which should concern bloginfo(‘name’) and bloginfo(‘description’) only.

    I use the bloginfo filter to translate these strings. However you can try another filter which may work better with your theme (if they directly use get_option instead of bloginfo). Copy paste this in a file test.php

    <?php
    /*
    Plugin Name: tests for Polylang
    */
    
    add_filter('option_blogname', 'translate_bloginfo');
    add_filter('option_blogdescription', 'translate_bloginfo');
    
    function translate_bloginfo($value) {
    	return  __($value, 'pll_string');
    }

    Upload the file in your plugins directory and activate the plugin. And tell me if it solves your issue.

Viewing 15 replies - 1 through 15 (of 49 total)
  • The topic ‘[Plugin: Polylang] "Site Title" and "Tagline" are not changing’ is closed to new replies.