Viewing 9 posts - 1 through 9 (of 9 total)
  • Author
    Posts
  • #564547

    I have with great success implemented the code in functions.php and got a second image in the header.
    Using this guide: https://kriesi.at/support/topic/adding-468-x-60-banner-to-header/
    However I am trying to make the image link, but this causes the site to crash.

    I used this code:

    function after_head_image_func(){
    echo “<div class=’custom_content’></div>”;

    add_action(‘ava_after_main_menu’, ‘after_head_image_func’);

    It is not a http link but a tel: link if that makes any difference.

    Thanks

    #564563

    Hey sjasen!

    Can you wrap your code with code tags? or paste it on Pastebin or similar?

    Best regards,
    Josue

    #564577
    
    
    function after_head_image_func(){
    	echo "<div class='custom_content'><a href="tel:004512345678"><img src='_URL_'></a></div>";	
    }
    add_action('ava_after_main_menu', 'after_head_image_func');
    
    
    #565194

    Hi,

    Could you try single quotes instead of double to wrap the number?

    'tel:004512345678'

    Best regards,
    Rikard

    #565422

    That did the trick, thanks a lot. :)

    I just realised that responsiveness wise, it does not look very good on mobile, because the ekstra image overlaps the logo and the burger-menu.
    Any ideas hos to fix that problem ?

    #565444

    Hey!

    Can you please post the link to your page so we can see the issue and provide you an accurate solution? :)
    If you would like to hide your custom content on mobile, please add following code to Quick CSS in Enfold theme options under General Styling tab

    @media only screen and (max-width: 480px) {
    .custom_content { display: none !important; }}

    Regards,
    Yigit

    #565506

    Ok here is the URL in a PM,thanks.

    #565894

    Hi,

    Please try the following in Quick CSS under Enfold–>General Styling:

    @media only screen and (max-width: 768px) {
    .custom_content {
        top: 5px !important;
    }
    }
    

    Regards,
    Rikard

    #566018

    That did the trick.
    Thanks a lot As always incredible support from you guys. :)

Viewing 9 posts - 1 through 9 (of 9 total)
  • The topic ‘Header second image link’ is closed to new replies.