-
AuthorPosts
-
April 27, 2018 at 2:15 pm #947958
Hello dear Kriesi team,
is there a way to place a telephone number at the same height as the Menu and Logo instead of above?
I created a screenshot to explain what I mean.
Thank you very much!April 27, 2018 at 2:43 pm #947980Hey UNID2017,
Please check this link to add the phone number or any text next to the logo.
Best regards,
VinayApril 27, 2018 at 2:52 pm #947985Hi Vinay,
thank you very much, unfortunately none of the code snippets work for me.April 27, 2018 at 6:31 pm #948083Hi,
I have tested the below code in my installation and I assure you it works 100%
First, remove all previous code.
Add the below function to your child theme functions.php
add_filter('avf_logo_subtext', 'kriesi_logo_addition'); function kriesi_logo_addition($sub) { $sub .= '<span>+49 711 656782-17</span>'; return $sub; }
Copy the below code to your style sheet or add it to Quick CSS in Enfold > General Styling
.logo .subtext span { font-weight: 600; z-index: 999; display: inline-block; position: absolute; top: 0; right: -100%; color: red; }
Best regards,
VinayMay 2, 2018 at 10:52 am #949944Vinay! Thank you very much! :)
It works now. Thank you for the great help.
I just have one more thing to ask. When writing »Jetzt informieren: +49 711 656782-17« the text moves quite close to the Logo when the menu shrinks down. Is there a way to add some spacing between the logo and the phone number when the menu gets smaller from scrolling?
Additionally, is there a way to add an action to directly call the number when clicking it?Thank you for the amazing support!
May 4, 2018 at 2:18 am #951192Hi,
Please see this for Phone Number Links
To move the number on scroll, Try this code in the General Styling > Quick CSS field:#header.header-scrolled .subtext span { right: -190% !important; }
adjust to suit.
Best regards,
MikeSeptember 19, 2019 at 3:36 am #1139773Is there a way to do this and link the phone number with an “a tel:” separably from the logo href that links to site root?
Thanks
September 20, 2019 at 4:15 am #1140087Hi,
Adding the tel link (yellow in the screenshot) to the span creates a separate link below the logo link (green in the screenshot)
add_filter('avf_logo_subtext', 'kriesi_logo_addition'); function kriesi_logo_addition($sub) { $sub .= '<span><a href="tel://1-555-555-5555">+1 (555) 555-5555</a></span>'; return $sub; }
But I would recommend creating a header widget area and placing your phone link in it for better control.
Best regards,
MikeSeptember 20, 2019 at 5:18 pm #1140254//number contact next to logo
add_filter(‘avf_logo_subtext’, ‘kriesi_logo_addition’);
function kriesi_logo_addition($sub)
{
$sub .= “<span class=’logo-title’>”;
$sub .= ‘PH (651) 777-1200′;
$sub .= “</span>”;
$sub .= “<span class=’logo-title logo-subtitle’>”;
$sub .= ‘ ‘;
$sub .= “</span>”;
return $sub;
}This is the code that I am using now when I add a link it drop below the header.
- This reply was modified 5 years, 2 months ago by thesmokingpipeshop.
September 21, 2019 at 2:01 am #1140384 -
AuthorPosts
- The topic ‘Phone number next to Logo / Menu’ is closed to new replies.