1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

Help Linking Header To Website

Discussion in 'PHP' started by Aaron111, Sep 24, 2016.

  1. #1
    I have a new blog" its wordpress: and I cant find the location were to edit it" to make the header logo clickable to another webstie: here what i got in edt admin on this theme"

    my site is http://ganocafecoffee.com
    Its the FREE MH Magazine Lite Theme:


    Templates
    404 Template
    (404.php)
    admin.php
    (admin/admin.php)
    Archives
    (archive.php)
    Comments
    (comments.php)
    content-author-box.php
    content-header.php
    content-large.php
    content-loop.php
    content-none.php
    content-page.php
    content-single.php
    Theme Footer
    (footer.php)
    Theme Functions
    (functions.php)
    Theme Header
    (header.php)
    Homepage Page Template
    (homepage.php)
    Image Attachment Template
    (image.php)
    mh-compatibility.php
    (includes/mh-compatibility.php)
    mh-custom-functions.php
    (includes/mh-custom-functions.php)
    mh-customizer.php
    (includes/mh-customizer.php)
    mh-widgets.php
    (includes/mh-widgets.php)
    Main Index Template
    (index.php)
    Single Page
    (page.php)
    Search Results
    (search.php)
    Sidebar
    (sidebar.php)
    Single Post
    (single.php)
    Full Width Page Template
    (template-full.php)
    mh-custom-woocommerce.php
    (woocommerce/mh-custom-woocommerce.php)
    Styles
    Stylesheet
    (style.css)
    RTL Stylesheet
     
    Aaron111, Sep 24, 2016 IP
  2. PoPSiCLe

    PoPSiCLe Illustrious Member

    Messages:
    4,623
    Likes Received:
    725
    Best Answers:
    152
    Trophy Points:
    470
    #2
    It's either in the header or the index, although if they're doing something via an admin interface, it might be in the functions file as well.
     
    PoPSiCLe, Sep 24, 2016 IP
    Aaron111 likes this.
  3. qwikad.com

    qwikad.com Illustrious Member Affiliate Manager

    Messages:
    7,151
    Likes Received:
    1,656
    Best Answers:
    29
    Trophy Points:
    475
    #3
    My question would be what is so good about that template that you're trying to make it work? I'd use a different one and maybe even by-pass all that unnecessary php stuff. You'll be dealing with the same issues again and again in the future. Get a template that you can easily modify anytime you want.

     
    qwikad.com, Sep 24, 2016 IP
    Aaron111 likes this.
  4. Aaron111

    Aaron111 Well-Known Member

    Messages:
    4,301
    Likes Received:
    29
    Best Answers:
    0
    Trophy Points:
    185
    #4
    qwikad. its true" it must be mobile friendly though" also were can i get free code edible wp theme from???
     
    Aaron111, Sep 24, 2016 IP
  5. mmerlinn

    mmerlinn Prominent Member

    Messages:
    3,197
    Likes Received:
    818
    Best Answers:
    7
    Trophy Points:
    320
    #5
    I am thoroughly confused. WHY do you want to get a wp theme that you can EAT???
     
    mmerlinn, Sep 24, 2016 IP
  6. Aaron111

    Aaron111 Well-Known Member

    Messages:
    4,301
    Likes Received:
    29
    Best Answers:
    0
    Trophy Points:
    185
    #6
    PoPSiCLe I tried all file is their a special hyper link PHP code for this??
     
    Aaron111, Sep 24, 2016 IP
  7. Aaron111

    Aaron111 Well-Known Member

    Messages:
    4,301
    Likes Received:
    29
    Best Answers:
    0
    Trophy Points:
    185
    #7
    Its Edit . editing the files to link out
     
    Aaron111, Sep 24, 2016 IP
  8. PoPSiCLe

    PoPSiCLe Illustrious Member

    Messages:
    4,623
    Likes Received:
    725
    Best Answers:
    152
    Trophy Points:
    470
    #8
    Took a look at the theme, and damn is it a mess. I could probably figure out where the elusive main-heading/logo is hiding, and make it work as a link, but I think, in this case, it will be quicker and easier to just find a hook, and put the link in via javascript. Ie, find out what the class on the header/logo is, or if it has an ID, and use some javascript to wrap an <a> around it.
     
    PoPSiCLe, Sep 24, 2016 IP
  9. JohnMT

    JohnMT Peon

    Messages:
    1
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    1
    #9
    @Aaron111: It's actually default in WordPress that logo and/or header image link to your front page. Not sure why you would want to link your header image to a different site. However, when you check the theme file /includes/mh-custom-functions.php starting on line 132, you'll find this:

    if (get_header_image()) {
        echo '<a class="mh-header-image-link" href="' . esc_url(home_url('/')) . '" title="' . esc_attr(get_bloginfo('name')) . '" rel="home">' . "\n";
            echo '<img class="mh-header-image" src="' . esc_url(get_header_image()) . '" height="' . esc_attr(get_custom_header()->height) . '" width="' . esc_attr(get_custom_header()->width) . '" alt="' . esc_attr(get_bloginfo('name')) . '" />' . "\n";
        echo '</a>' . "\n";
    }
    PHP:
    You can customize this as you like and link the header image to your preferred location. But keep in mind that when customizing WordPress themes, you should not edit core theme files, but create a child theme instead. Otherwise your changes will be lost after theme updates anyway.
     
    JohnMT, Sep 25, 2016 IP
  10. PoPSiCLe

    PoPSiCLe Illustrious Member

    Messages:
    4,623
    Likes Received:
    725
    Best Answers:
    152
    Trophy Points:
    470
    #10
    I rest my case. Anyone writing shit like that shouldn't be let near php. Or html. Makes me sad.
     
    PoPSiCLe, Sep 25, 2016 IP