It is impossible to insert 2 different logos into the template
-
I’m trying to make a logo in 2 languages
In one, the default language is in Russian.
The second logo I have is the second picture of the logo.
Here’s the code:
<div class=”site-logo”>
<div class=”woodmart-logo-wrap<?php if( $has_sticky_logo ) echo ” switch-logo-enable”; ?>”>
” class=”woodmart-logo woodmart-main-logo” rel=”home”>
<?php echo ‘
‘; ?>
<?php if ( $has_sticky_logo ): ?>
<?php
$logo_sticky = $protocol . str_replace( array( ‘http://’, ‘https://’ ), ”, $logo_sticky_uploaded[‘url’] );
?>
” class=”woodmart-logo woodmart-sticky-logo” rel=”home”>
<?php echo ‘
‘; ?>
<?php endif ?>
</div>
</div>
I’m trying to do this way
<? php $ logo =! strpos ($ _ SERVER [‘REQUEST_URI’], ‘/ he /’)? $ logo: ‘https://tophome.co.il/wp-content/uploads/2018/01/logo-il-big-1.png’; ?>
<? php echo ‘
‘; ?>
*** https://tophome.co.il/wp-content/uploads/2018/01/logo-il-big-1.png – address of the picture(logo) in Hebrew
SITE :https://tophome.co.il/ – russian
SITE :https://tophome.co.il/he/ – hebrew
I ask you to help me, what I’m doing wrong.
Hello,
We are glad to know that you considered using WoodMart for your web-site. I hope you will be happy with it.
Sorry, but your code is not quite clear for us. How exactly do you create multilanguage website? Do you use WPML plugin for that?
Kind Regards
Xtemos
Yes, that’s right, I’m using the plugin WPML
Already decided I need just this code to write
if ( ICL_LANGUAGE_CODE == ‘he’ ) {
//show HEBREW logo
} elseif ( ICL_LANGUAGE_CODE == ‘ru’ ) {
// show russian logo
}
Thanks.
Hi,
We are glad that you found the solution. But in most cases, theme settings values can be set for different languages with String Translations option in WPML.
Regards