Skip to main content
higgsyd
Inspiring
Apr 15, 2020 8:02 AM UTC
Answered

How to centralise my menu

Can any of you kind souls show me how to move this menu into the middle of the page please?  I have tried the margin 0 auto thing on both the nav tag and also on the .menu class.  After fiddling around for a couple of days it still sticks resolutely to the far left edge!  The page is at: http://v45.ancestry.higgsy.co.uk/menu3.html Thanks

This topic is closed to new replies. Start a new post to keep the conversation going.
osgood_Correct answer
Legend
Apr 15, 2020 8:33 AM UTC

Add the below selector to your css styles:

 

nav {
display: flex;
justify-content: center;
background-color: #515f9c;
}

2 replies

osgood_Correct answer
Legend
Apr 15, 2020 8:33 AM UTC

Add the below selector to your css styles:

 

nav {
display: flex;
justify-content: center;
background-color: #515f9c;
}

Translate
higgsyd
higgsydAuthor
Inspiring
Apr 15, 2020 11:34 AM UTC

brilliant! osgood saves the day again, many thanks, David

Translate