Nav fixed to left column of the screen

Nav fixed to left column of the screen
0

Nothing seems to be working. I need to get it to float center somehow without messing my layout.

Here is my pen:
https://codepen.io/KobadaTech/pen/NZoBaL

Not sure what you mean by “it”. If you are asking why you are failing the one test, it is because the project tests are expecting you navbar element to be a direct child of the body element. Your navbar element is nested deep inside a div with class=“wraper”.

I’ve moved my nav to directly under the body element. I also managed to get the nav to lay horizontally accross the top. However, it is now saying the navbar should always be at the top of the viewport. I tried using position:fixed; for nav but that didn’t work either.

  1. On .nav you have a colon after position: fixed, it should be a semicolon.

  2. If you move position: fixed; to the #navbar element it will pass the test. You will have to make some changes to make it look the same.

1 Like

Thanks mate that done the trick!