Archived topic
Wrong link from mobile logo in header (using Polylang)
3 replies · Started by Oleh on January 12, 2019
Hi there!
The theme is working strange with Polylang.
When I'm on any page of my second language from mobile device and press on the logo it leads me to the English home page, instead of leading to the second language home page.
On Desktop everything works fine.
I'm talking about this url:
#mobile-header > div > div.site-logo.mobile-header-logo > a
I hope you can help me with this issue.
Hi there,
Can you try this function?:
add_filter( 'generate_logo_href', function( $url ) {
if ( function_exists( 'pll_home_url' ) ) {
return pll_home_url();
}
return $url;
} );
Let me know :)
Hi Tom,
Thank you, it works now!
You're welcome :)