The objective is maintaining all of my site urls, only the logo have to link to the principalk website (different from my home page).
If someone have any idea where I can change that I would appreciate your suggestions to bring some light to the dark.
Thank you so much in advance for your time.
]]>Right now my logo in the header point at the frontpage. It’s fine at some landing pages but when the users are behind the login-wall I would prefer the logo in header link point at another URL than my front page.
Is this possible and if it is: What do I need to do?
]]>In my child theme the logo html is specified in the “template-part-head” file. The original php code didn’t work:
<header id="site-header" role="banner">
<?php if (get_theme_mod('header-logo', '') != '') : ?>
<div class="rsrc-header-img">
<a href="<?php echo esc_url(home_url('/')); ?>"><img src="<?php echo esc_url(get_theme_mod('header-logo')); ?>" title="<?php echo esc_attr(get_bloginfo('name', 'display')); ?>" /></a>
So I changed the child theme code to be the domain url instead:
<a href="https://collectiblesandmoreinstore.com"><img src="<?php echo esc_url(get_theme_mod('header-logo')); ?>" title="<?php echo esc_attr(get_bloginfo('name', 'display')); ?>" /></a>
Then I changed the child theme code to the exact url instead:
<a href="https://collectiblesandmoreinstore.com/best-collectibles-store/"><img src="<?php echo esc_url(get_theme_mod('header-logo')); ?>" title="<?php echo esc_attr(get_bloginfo('name', 'display')); ?>" /></a>
Then I changed the parent theme template-part-head to use the exact url also. Then I changed the img src php code to reference the specific media file url instead:
<a class="header-logo-link" href="https://collectiblesandmoreinstore.com/best-collectibles-store/"><img src=”https://collectiblesandmoreinstore.com/wp-content/uploads/2021/07/collectiblesandmoreinstore-logo.png” height=”110” width=”350” alt=”collectiblesandmoreinstore logo"/></a>
In addition, I have this code in my child theme functions.php:
add_theme_support( 'header-logo' );
function my_header_logo() {
$header_logo_id = get_theme_mod( 'header_logo' );
if ( $header_logo_id ) {
$header_logo_attr = array(
'class' => 'header-logo',
'itemprop' => 'logo',
'height' => 110,
'width' => 350,
'flex-width' => true,
'header-text' => array( 'site-title', 'site-description' ),
);
$size = getimagesize("https://collectiblesandmoreinstore.com/wp-content/uploads/2021/07/collectiblesandmoreinstore-logo.png");
$image_alt = get_post_meta( $header_logo_id, 'wp_attachment_image_alt', true );
if ( empty( $image_alt ) ) {
$header_logo_attr['alt'] = get_bloginfo( 'name', 'display' );
}
$html = sprintf( '<a href="https://collectiblesandmoreinstore.com" class="header-logo-link" rel="home" itemprop="url" title="Collectibles And More In-Store"/></a>',
esc_url( home_url( 'https://collectiblesandmoreinstore.com/best-collectibles-store/' ) ),
esc_html( get_bloginfo( 'name' ) ),
wp_get_attachment_image( $header_logo_id, 'full', false, $header_logo_attr )
);
}
elseif ( is_customize_preview() ) {
$html = sprintf( '<a href="https://collectiblesandmoreinstore.com" class="header-logo-link" style="display:none;"><img class="header-logo"/></a>',
esc_url( home_url( 'https://collectiblesandmoreinstore.com/best-collectibles-store/' ) )
);
}
return $html;
}
add_filter( 'get_header_logo', 'my_header_logo' );
Additionally, I have cleared my site cache, browser cache, server cache, and image cdn cache. Please tell me what I am doing wrong. I need please to have my logo link back to my domain url (homepage/landing page).
Thank you for your assistance.
]]>I am trying to change the blog logo URL to another URL. The scenario is as follow:
the blog is installed in folder for example domain.com/blog and I want the logo to link to domain.com.
I’ve tried all snippets and filters that were discussed before in the forum, but none of those worked. I also tried to use JS, but also didn’t worked. The theme is premium and it is called Saasland. Unfortunately, the marketplace code is already expired by a month.
Thank you!
]]>Whenever someone clicks on the logo of my website, they redirected to the developers’ website which is https://crunchify.com I’m not able to understand why this is happening.
Looking for immediate help from the developers as this issue redirecting my users to a totally different website and my customers are complaining about this issue.
Please help.
]]>Can you please support me with the following issue?
I added a logo image and adjusted the size. Unfortunately the area over the logo in which I can hover over to access the Home page is too small. The result is that the left part of the logo is clickable.
How can this be fixed so that the clickable area corresponds to the whole logo?
Thank you!
]]>I use 2 languages ??on my website (EN-TR). The logo in the title section has a link to the home page. When I switch to another language and click on the logo, it goes to the home page of the first language.
What I want to do is go to the home page of the selected language when I click on the logo.
Thanks,
]]>Please help me . Thanks
]]>Thank you!
]]>