murab
March 8, 2018, 10:11am
1
Hi,
Thank you for creating an awesome theme.
I’ve been making minor changes and enjoying a lot.
And one thing I can’t figure out…
How can I change the header logo link to an external website?
I’ve tried through replacing the below code in header.php to the website address, but it didn’t work…
<?php echo esc_url( home_url( ‘/’ ) ); ?>
thank you for your help!
Hello there,
I hope you are doing well today.
You can try using the following plugins to manage the external links:
Best Regards,
Support
murab
March 9, 2018, 6:05am
3
Thank you for your assistance.
I installed the plugins you mentioned, but they don’t have a function to set the header logo link to the one that is not a blog top.
Are there any other ways to replace the link for the header logo?
By the way, I use the theme, Activello.
Thanks,
Hey there
You can use Jquery for this:
jQuery("a.custom-logo-link").attr("target","_blank");
install this plugin:
and then in the header code add this code:
jQuery(document).ready(function($) {
jQuery("a.custom-logo-link").attr("target","_blank");
})
murab
March 9, 2018, 11:56am
5
Hi,
Thank you for your help.
I’m totally new to Jquery…and sorry for all these questions…
I understood about installing the plugin, and I did. After that, what do I do?
Do I add this code in header.php? or in “Add Js code” in the plugin?
jQuery(document).ready(function($) {
jQuery(“a.custom-logo-link”).attr(“target”,"_blank");
})
And what about the 1st code you mentioned?
jQuery(“a.custom-logo-link”).attr(“target”,"_blank");
Do I place it somewhere in the plugin?
And after setting all these codes in the right place, how and where do I place the target website address for the header logo? Do I have to edit php file?
Thank you,
murab
March 9, 2018, 12:15pm
6
I think I figured out about where to put the codes…
(I added the code below in “Add Custom JS,” choosing “External link” and “Header.”… is that right?)
jQuery(document).ready(function($) {
jQuery(“a.custom-logo-link”).attr(“target”,”_blank”);
})
But it still doesn’t direct the header logo to the external link…What should I do next??
Thank you again for your help!
Hi there
Let me set up this for you please send me your access credentials along with your website URL and I will investigate this case. Don’t forget to mark your reply as private! Thanks!
Colorlib Support Team
murab
March 12, 2018, 6:37am
8
Hi
Thank you for your support.
I googled and figured out over the weekend!
I appreciate your help
Hi, there
Nice to hear your problem is fixed:)
I will now close the topic and mark it as resolved.
Feel free to contact us again Thanks!