-
AuthorPosts
-
January 13, 2016 at 11:42 am #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
January 13, 2016 at 12:00 pm #564563Hey sjasen!
Can you wrap your code with code tags? or paste it on Pastebin or similar?
Best regards,
JosueJanuary 13, 2016 at 12:15 pm #564577function 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');January 14, 2016 at 4:28 am #565194Hi,
Could you try single quotes instead of double to wrap the number?
'tel:004512345678'Best regards,
RikardJanuary 14, 2016 at 3:22 pm #565422That 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 ?January 14, 2016 at 3:45 pm #565444Hey!
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,
YigitJanuary 14, 2016 at 4:31 pm #565506Ok here is the URL in a PM,thanks.
January 15, 2016 at 4:06 am #565894Hi,
Please try the following in Quick CSS under Enfold–>General Styling:
@media only screen and (max-width: 768px) { .custom_content { top: 5px !important; } }Regards,
RikardJanuary 15, 2016 at 10:00 am #566018That did the trick.
Thanks a lot As always incredible support from you guys. :) -
AuthorPosts
- The topic ‘Header second image link’ is closed to new replies.
