WordPress.org

Support

Support » How-To and Troubleshooting » Make Image Header Clickable to HOME in Minimatica

Make Image Header Clickable to HOME in Minimatica

  • HI Guys

    i’ve googled extensively and all the links i find are dead 🙁

    Please can someone tell me how to make my uploaded header image, clickable to my homepage on my wordpress minimatica themed website?

    My site is on MAMP atm so i can’t give an example, but would appreciate know where to add or change code to make this happen

    I’ve been able to make the header clickable but then i lose my image for some reason :-/

    Thanks!

Viewing 2 replies - 1 through 2 (of 2 total)
  • figured it out if anyone wants to know

    replace the following text in header.php from

    <header id="header" role="banner">
    <?php $heading_tag = ( is_home() || is_front_page() ) ? 'h1' : 'div'; ?>
    <<?php echo $heading_tag; ?> id="site-title"><a>" title="<?php echo esc_attr( get_bloginfo( 'name', 'display' ) ); ?>" rel="home"><?php bloginfo( 'name' ); ?></a></<?php echo $heading_tag; ?>>
    </header><!-- #header —>

    to

    <header id="header" role="banner" onclick="location.href='http://www.yoursite.com';" style="cursor: pointer;" title=Home>
    <?php $heading_tag = ( is_home() || is_front_page() ) ? 'h1' : 'div'; ?>
    <header id="header" role="banner">
    <<?php echo $heading_tag; ?> id="site-title"><a>" title="<?php echo esc_attr( get_bloginfo( 'name', 'display' ) ); ?>" rel="home"><?php bloginfo( 'name' ); ?></a></<?php echo $heading_tag; ?>>
    </header><!-- #header -->

    [Moderator Note: Please post code & markup between backticks or use the code button. Your posted code has now been permanently damaged by the forum’s parser.]

    okay, for some reason that code messes with lightbox, not sure why, seems it redirects the image links to the homepage too.

    So frustrating

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Make Image Header Clickable to HOME in Minimatica’ is closed to new replies.
Skip to toolbar