[Resolved] Remove Logo Link to Homepage

Home Forums Support [Resolved] Remove Logo Link to Homepage

Home Forums Support Remove Logo Link to Homepage

Viewing 14 posts - 1 through 14 (of 14 total)
  • Author
    Posts
  • #128161
    Martin

    Hi

    There doesn’t seem to be an obvious setting for this and wondered how to remove the logo link to the homepage of the site?

    Thanks

    Martin

    #128162
    Tom
    Lead Developer
    Lead Developer

    Do you want to remove the link altogether or just change it to a different page?

    #128163
    Martin

    I originally thought remove but change would be better?

    Thanks

    Martin

    #128164
    Tom
    Lead Developer
    Lead Developer
    #128589
    Martin

    That’s great Tom. Thank you.

    #128590
    Martin

    Sorry Tom, I thought I had it.

    When it says // Enter the URL you want your logo to link to below
    return ‘http://generatepress.com’; …

    … where exactly do I put it?

    Thanks

    Martin

    #128626
    Martin

    Think I might have cracked it. Does the url need to be enclosed in “url”?

    Thanks

    Martin

    #128657
    Tom
    Lead Developer
    Lead Developer

    You would replace http://generatepress.com with your URL.

    So it would be:

    add_filter( 'generate_logo_href','generate_custom_logo_href' );
    function generate_custom_logo_href()
    {
    	// Enter the URL you want your logo to link to below
    	return 'http://YOURURLHERE.com';
    }
    #128672
    Martin

    That was obvious wasn’t it? 🙂 Thanks again for your help.

    #128673
    Tom
    Lead Developer
    Lead Developer

    No problem! 🙂

    #246992
    willworksdesigns

    Hi Tom,

    Question: How can I alter the site name link in header to match that of the altered logo?

    Thanks for the simple PHP plugin and the directions for adding the PHP to change the logo link in the header. It is simple to do. However, while the header logo links to another URL, the site name, an active link, needs to be changed to match that of the logo. Do you have another snippet of PHP that will allow me to change the site name URL as well?

    PS: I use the paid version of GeneratePress (along with Visual Composer and a suite of add-ons) and LOVE it! Thanks for your hard work and commitment to GP.

    Cheers,
    Will

    #247017
    Tom
    Lead Developer
    Lead Developer

    Absolutely! You would do this:

    add_filter( 'generate_site_title_href','generate_custom_site_title_href' );
    function generate_custom_site_title_href()
    {
    	// Enter the URL you want your logo to link to below
    	return 'http://YOURURLHERE.com';
    }

    Glad you’re enjoying GP! 🙂

    #247097
    willworksdesigns

    Tom, thanks very much for this! Best wishes to you and your family…

    #247165
    Tom
    Lead Developer
    Lead Developer

    You too! 🙂

Viewing 14 posts - 1 through 14 (of 14 total)
  • You must be logged in to reply to this topic.