• I am just starting to build my website at https://nerybauer.com/temp/. I would like to change the position of the navigation bar, to the right side of the logo. The menu has few items and there is plenty of space to it.
    Is it possible to do just using css, or should I play a bit with php to do it?

    Thanks very much.

Viewing 3 replies - 1 through 3 (of 3 total)
  • It can be easily done using css. No need to touch php till you can play with css and get the thing done.

    Add following code to style.css.

    .main-nav {
    clear: both;
    margin: -100px 0 30px 0;
    width: 50%;
    float: right;
    }

    I ve tried this using inspect element and it’s working fine as you want — nav on right side in line with logo.

    Cheers ??

    Tejas

    Thread Starter neryba

    (@neryba)

    Tejas Gandhi, thank you very much for your help.

    With the changes you suggest, it works fine when I use browser width in full. But if I make it smaller in width, or if looking at it in a device with a smaller screen, things go wrong. As you an se live in https://nerybauer.com/temp/, in some sizes the nav bar goes over the logo, in others it dont get aligned with the logo horizontaly, etc… So, I think this change dont solve my problem.

    I dont know very much css… but two things come to mind. Maybe instead of using “-100px” on the left margin we should use something relative, not absolute? Like, “-50%” ? And, if we use a ‘display’ function wouldnt it work better, maybe using ‘inline’ value? I tried some of it but with no luck, maybe becasue Im not putting it in the right place.

    Hi

    Let me try working on it. Will get back once done.

    Happy to help:)

    Tejas

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Change Menu Position’ is closed to new replies.