Jump to content
juvv

How to center-align the Fixed Navbar?

Recommended Posts

juvv    0
juvv

Hi there,

I am trying to center-align the menu items in my fixed navbar and also have them spread out so they are wide enough to fill up the whole navbar (the same width as the content area), however cannot figure out how to do so.

In the options, I noticed that there were options to either left-align it or right-align it but nothing to center-align it - which is why I am here!

My site is http://www.aprilialove.com

I would also like to know how to change the font of these menu items? Is there an option or will I need to insert some code into the CSS sheet?

Thanks!

Share this post


Link to post
Share on other sites
Danny    1,327
Danny

Hi,

Add the following code:


#site .section-navbar.fixed-top .navline { text-align: center; float: none; }
#site .section-navbar.fixed-top .navline > li { float: none; display: inline-block; }[/CODE] If you do not wish to have your drop down menus aligned center, use the following code:
[CODE]#site .section-navbar.fixed-top .navline > li > ul > li { text-align: left; }
If you wish to give a larger space between menu items add the following code:
#site .section-navbar.fixed-top .navline > li > a { padding: 10px 25px 10px; }[/code]

  • Like 1

Please search our forums, before posting!

Share this post


Link to post
Share on other sites
juvv    0
juvv

Hi there,

Thanks for this - your help is much appreciated!

How do I actually change the font of the menu items though?

Share this post


Link to post
Share on other sites
Danny    1,327
Danny

You can change your menu item font family by selecting what font you like in PageLines > Site Options > Typography.

However, you can also target them using CSS, add the code below and add your preferred font family.

#site .section-navbar.fixed-top .navline > li > a { font-family: Add font here; }[/CODE]


Please search our forums, before posting!

Share this post


Link to post
Share on other sites
juvv    0
juvv

Great, thanks for your help.

You can now close the case as the problem was resolved! :)

Share this post


Link to post
Share on other sites
Danny    1,327
Danny

The topic was marked as resolved.


Please search our forums, before posting!

Share this post


Link to post
Share on other sites
justonline_be    0
justonline_be

Dear

I've tried to add this code to the css, but it don't work. Is there an other place where i need to add this code?

Thanks a lot for your help

 

Share this post


Link to post
Share on other sites
Rob    547
Rob

Add the code to Dashboard > PageLines > Site Options > Custom Code.

 

Please note, this topic is marked closed. If you have further questions, kindly open a new topic.  Thanks.


Former PageLines Moderator, Food Expert and Raconteur

Share this post


Link to post
Share on other sites
Guest
This topic is now closed to further replies.

  • Similar Content

    • Grant Turck
      By Grant Turck+
      Navbar Broken on All Devices When Not Logged Into Wordpress. See screenshots attached from mobile. What is causing this issue and how do I fix? Site is venicepride [dot] org.


    • PierreFF
      By PierreFF+
      Hello, 
      I have an issue with NavPro on mobile when the link of the menue is on the same page. 
      Here is my website: http://foundersofthefuture.co
      The isssue comes from the fact that in my menue most of the items send somewhere else on the same page using anchor link (eg. #container_u788888). 
      This works well on desktop but on mobile, nothing happens when clicking on the link. One of the link of the menue of the homepage "France" sends to another page of the website and this one works well even on mobile. 
      I am using the Pagelines framework theme and also used a wordpress plugin (jQuery Smooth Scroll) for smooth scrolling . 
      Thanks in advance for your help and let me know if I need to provide more information. 
      Best,
      Pierre
    • tristanrodgers
      By tristanrodgers+
      Hi there!
      I'd love to have some social media buttons in my navbar like my online-shop has!
      http://mc1r-magazine.com/
      Can someone explain me how to create them? I tried a lot but don't know how to realize them...
      Greetings from Germany,
      Tristan
    • jeomiland
      By jeomiland+
      Hi guys. Just now trying out Platform 5. I like the reletive simplcity of the new interface but there are things I'm used to in DMS that I'm not seeing yet in 5. Is there a good manual, documentation, video series about some of the basics?
      In particular, I've got a simple navigation menu, created the standard way in WP menus section with several top level parents, then 3-4 children menu items below a couple parent items. Have them moved to the right to create the standard parent-child relationship but all I see on the page is the parent level items - no dropdown!. So I changed themes from Platform5 to the standard 2015 default theme and now I see absolutely no menu at top, except for the mobile (hamburger?) icon.
      In DMS, one had Navi and Navbar, etc sections and each would work differently and give different results. How do you work the menu system in 5? And how get different results ?
      thanks
    • nizami
      By nizami+
      I have a problem at http://kambo.world. Using navbar for the main site navigation. It works fine in normal/desktop mode [first screenshot], using the WP Menu I have specified. But in hamburger mode it seems to do its own thing, picking a few pages at random [second screenshot] A fix for this greatly appreciated! 
       


×