• Resolved Saint Patrick

    (@saint-patrick)


    I can’t seem to change the link in the header image to anything but the homepage. I’ve tried changing in header.php but I don’t see anything that let’s me change it there.

Viewing 5 replies - 1 through 5 (of 5 total)
  • Hy Saint Patrick,

    Do you mean the link when clicked on the logo or the link of the homepage menu button?

    Kind regards,

    Larsen

    Thread Starter Saint Patrick

    (@saint-patrick)

    I meant the logo, specifically.

    Hy,

    In the theme functions.php file on line 155 you will find the following code:

    /***** Logo / Header Image Fallback *****/
    
    if (!function_exists('mh_logo')) {
    	function mh_logo() {
    		$header_img = get_header_image();
    		echo '<div class="logo-wrap" role="banner">' . "\n";
    		if ($header_img) {
    			echo '<a href="' . esc_url(home_url('/')) . '" title="' . get_bloginfo('name') . '" rel="home"><img src="' . $header_img . '" height="' . get_custom_header()->height . '" width="' . get_custom_header()->width . '" alt="' . get_bloginfo('name') . '" /></a>' . "\n";
    		} else {
    			echo '<div class="logo">' . "\n";
    			echo '<a href="' . esc_url(home_url('/')) . '" title="' . get_bloginfo('name') . '" rel="home">' . "\n";
    			echo '<h1 class="logo-name">' . get_bloginfo('name') . '</h1>' . "\n";
    			echo '<h2 class="logo-desc">' . get_bloginfo('description') . '</h2>' . "\n";
    			echo '</a>' . "\n";
    			echo '</div>' . "\n";
    		}
    		echo '</div>' . "\n";
    	}
    }

    You can edit and change the link here.

    Thread Starter Saint Patrick

    (@saint-patrick)

    Excellent! Thank you very much. That’s exactly what I needed.

    Thanks Larsen!

    Your welcome.

    Goodluck!

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Can't change link in header’ is closed to new replies.