Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS horizontal menu – position submenu on top

  • This topic is empty.
Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
    Posts
  • #37044
    lorem
    Participant

    Hi there,

    i try to recreate this menu: http://splyte.de/menu/menu.jpg

    the problem is now, that the submenu is positioned below the list-element on hover and I would like to position it on top, see here: http://splyte.de/menu/index.html (menu 02)

    any ideas how I could achieve this? or links to similar looking menus for inspiration?

    thanks in advance, jan

    #98474
    Senff
    Participant

    Try applying a negative top margin to header nav ul ul, of -90px or so, then fix the positioning of the entire menu a little bit so that the top isn’t cut off.

    #98477
    lorem
    Participant

    Hi Senff,

    thanks for replying!

    meanwhile i figured out that adding position absolute and a value for bottom will position the submenu in the desired way. (updated link). the problem is now, that it should dynamically position on top of the menu-text, no matter if the text is in one line or broken in two.

    any ideas?

    thanks, jan

    #98479
    Senff
    Participant

    This may be a solution: http://jsfiddle.net/senff/6JBCA/

    #98484
    lorem
    Participant

    thanks a lot, looking good!! :)

    I’ll check, if we can adopt the markup. does this validate?

    #98487
    Senff
    Participant

    I would never provide any types of hacks or dirty code. ;)

    #98489
    lorem
    Participant

    hehe :)

Viewing 7 posts - 1 through 7 (of 7 total)
  • The forum ‘CSS’ is closed to new topics and replies.