• Hi
    I use polylang 1.0.4 and responsive theme and I have a bilingual website and a graphic header. I would like to display 2 header for each language. Have anyone achieved this?

    My other language is Persian (right to left) and every time I switch language the header moves left and right. It’s awful!

    Thanks in advance.

    https://www.ads-software.com/extend/plugins/polylang/

Viewing 4 replies - 1 through 4 (of 4 total)
  • Hi I have just used this same method for my site. Instead of a header it is called callout section, which containes the callout_image.
    Latest versions everywhere. Plus using pagelines theming with childtheme iblogpro5. I have a callout image on my main page. Tried to apply the header_image example to mine but nill.

    have tried changing the themes path, i do not have any mods folder from themes to pagelines, also tried pagelines-iblogpro5, and nothing

    Paths to themes are “themes/pagelines”

    Plugin Author Chouby

    (@chouby)

    @hzend. Does the method described on the Polylang blog work for you?

    @daliak. I am not familiar with the pagelines framework. How do setup this callout image?

    Hi Chouby,
    No it doesn’t work, I tried the example you gave above re header image which looked pretty much the same. but nill, not a move.

    basically pagelines via templating installs sections, then you play via drag & drop. Sections are in php and cssed in less.

    Normally I get polylang admin to make available similar sections ie features, sliders, boxes etc. All that is then multiplied by the # of languages and on each i can write the appropriate languages…. but the callout can be just an image and i have no knowledge of php. The only thing i could think of was to write the text in php instead of having it in the image… but then i need to play with fonts and css to get similar effect…. thought doing the trick like for the header image would suffice..

    Sorry to write such a long message.
    Can you help?
    Thanks
    Dalia

    Plugin Author Chouby

    (@chouby)

    Could you try something like this in functions.php or in a custom plugin?

    add_filter('ploption_pagelines_callout_image', 'translate_callout_image');
    
    function translate_callout_image() {
    	$loc = get_locale();
    	if ( $loc == 'fr_FR')
    		return 'https://yoursite.com/fr.jpg';
    	if ( $loc == 'en_US')
    		return 'https://yoursite.com/en.jpg';
    
    }
Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Translate "the header"’ is closed to new replies.