• Resolved Jotrobo

    (@jotrobo)


    Hi, I installed the polylang plugin. It’s running fine, but I don’t know how translate the content of theme options like sections(services). Is it possible to tranlate?
    Thanks for all!

Viewing 3 replies - 1 through 3 (of 3 total)
  • Theme Author sonalsinha21

    (@sonalsinha21)

    Thread Starter Jotrobo

    (@jotrobo)

    Please, tell me if I understood correctly.
    I have to add this code in the functions.php of the skt white theme:

    // [polylang lang=”en”]English[/polylang][polylang lang=”sp”]Spanish[/polylang]
    function polylang_shortcode($atts, $content = null)
    {
    if (empty($content))
    return ”;
    extract( shortcode_atts( array(‘lang’ => ”), $atts ) );
    if (empty($lang))
    return “<h3>You must specify ‘lang’ using shortcode: polylang</h3>”;

    return ($lang == pll_current_language()) ? $content : ”;
    }
    add_shortcode(‘polylang’, ‘polylang_shortcode’);

    And then I have to insert the shortcode…
    [polylang lang=”en”]English[/polylang][polylang lang=”sp”]Spanish[/polylang]
    where?

    Excuse my poor english, the post that you recommend me is full of technics words xD too much for my knowledge.
    Thans a lot for your patient, I hope you will can help me to solve this situation.

    Hi,

    Sorry to jump into the conversation but I am having the same problem and couldn’t find out how to use the workaround proposed in the other post. Did you find out?

    Thank you and have a nice day.
    Kind Regards.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Polylang & Theme option’ is closed to new replies.