Viewing 15 replies - 1 through 15 (of 19 total)
  • If you want to link you whole header to home page. You should go with jquery:

    <script type="text/javascript">
    $(function(){
      $("#header").bind('click', function(){
        var url = "https://www.releasethereal.com/";
        $(location).attr('href',url);
      });
    });
    </script>

    Write the above mentioned code in your header.php just before closing head tag.

    Thread Starter Jackie Chan

    (@jackie-chan)

    Thanks ill give that a go. Also is it possible for just the logo to have a link, rather than the whole header?

    Also i just tried that code before </head> in the header.php and had no luck

    Thread Starter Jackie Chan

    (@jackie-chan)

    Any ideas?

    Currently, your logo is a part of header background image. So to make it link you have extract logo from background image and make it link.

    Thread Starter Jackie Chan

    (@jackie-chan)

    Ok ill go with the first one (Link the whole header) i added the code to header.php above the closing head tag (/head) however this had no effect, am i pasting the code into the wrong place?

    Code is not showing on live site view source. If you are working on your local system. just check your jquery script is working fine.

    To check this write alert under ready function:

    <script type="text/javascript">
    $(function(){
     alert("hello");
    });
    </script>

    I will suggest you to extract your logo from background image of header and place it as individual element and link it. It is because when you will click any element under your header section it will trigger that header click event.

    Thread Starter Jackie Chan

    (@jackie-chan)

    Ok ill try extracting the logo, how would i go about placing the JPEG on top of the header?

    After extracting logo > get width and height of logo > go to your stylesheet and make the following changes:

    CSS Code:

    #logo a{
     display:block;
     float:left;
     width: (logo width in px);
     height: (logo height in px);
     text-indent:-999em;
    }

    I missed to include background image:

    #logo a{
     display:block;
     float:left;
     width: (logo width in px);
     height: (logo height in px);
     background:url(images/logo.jpg) no-repeat 0 0;
     text-indent:-999em;
    }

    Logo image url should be relative as given above e.g. (images/logo.jpg)

    Thread Starter Jackie Chan

    (@jackie-chan)

    Thanks, right i’ve added this code and added a code to hyperlink the logo, however nothing has changed, any ideas?

    It is because you have written the following code in your header.php under style tag:

    #header h1, #header #desc { display: none; }

    So please comment this code from header.php file and then try.

    Thread Starter Jackie Chan

    (@jackie-chan)

    I’ve just searched through the header.php (word for word) via wordpress editor and that code does not seem to be in there, any ideas?

    When I am view source of your file it is showing there. I am not sure but it should be under header.php. Please view source of your site.

    Thread Starter Jackie Chan

    (@jackie-chan)

    Found it in functions.php, this now shows the site title and only a portion of the image ive tried changing the dimensions but it does not effect the image size :/

Viewing 15 replies - 1 through 15 (of 19 total)
  • The topic ‘Link header to homepage’ is closed to new replies.