Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter Mankov

    (@mankov)

    If you click on the zerfie lite theme’s logo, it refers to the main-page of the site. How can we install an external link on the logo. So by clicking on the logo it should refer to an external website. Must be somewhere in the .php-documents, but we don’t know exactly where.

    • This reply was modified 8 years, 1 month ago by Mankov.
    • This reply was modified 8 years, 1 month ago by Mankov.
    • This reply was modified 8 years, 1 month ago by Mankov.
    • This reply was modified 8 years, 1 month ago by Mankov.
    Thread Starter Mankov

    (@mankov)

    Can you tell us in which php-document and phrase we have to paste your code?

    mdshak

    (@mdshak)

    Hi,
    Please paste the code at functions.php of child theme. Make sure to use a child theme to make these changes: https://docs.themeisle.com/article/14-how-to-create-a-child-theme.

    
    add_filter( 'get_custom_logo', 'mdshak_url' );
    function mdshak_url() {
        $custom_logo_id = get_theme_mod( 'custom_logo' );
        $html = sprintf( '<a href="%1$s" class="custom-logo-link" rel="home" itemprop="url">%2$s</a>',
                'INSERT URL HERE', // DONT FORGET TO CHANGE THE URL
                wp_get_attachment_image( $custom_logo_id, 'full', false, array(
                    'class'    => 'custom-logo',
                ) )
            );
        return $html;   
    } 

    Thanks
    Mohammad

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Logo – external link’ is closed to new replies.