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

Home Forums CSS wanting submenu to dropdown vertically but they are floating left. Any suggestions?

  • This topic is empty.
Viewing 1 post (of 1 total)
  • Author
  • #36940

    I built horizontal menu with css and one dropdown submenu to dropdown vertically when mouse hovers. Tried to add another submenu underneath first but it goes horizontal left.

    css code is:
    #content {
    background-color: #FFFFFF;
    padding: 10px;
    margin-top: 10px;
    margin-right: auto;
    margin-bottom: 10px;
    margin-left: auto;
    background-attachment: fixed;
    color: #000;
    #nav {
    width: 100%;
    float: left;
    padding: 0;
    background-color: #f2f2f2;
    border-bottom: 1px solid #ccc;
    border-top: 1px solid #ccc;
    height: auto;
    margin-top: 0;
    margin-right: 0;
    margin-bottom: 3em;
    margin-left: 0;
    list-style-image: none;
    list-style-type: none;
    #nav li
    float: left;
    #nav ul
    { float: none;
    #nav li a {
    display: block;
    font-weight: bolder;
    color: #4171b8;
    font-family: “Monotype Corsiva”;
    font-size: 20px;
    height: 12px;
    padding-top: 8px;
    padding-right: 15px;
    padding-bottom: 8px;
    padding-left: 15px;
    line-height: 12px;
    text-transform: none;
    text-align: center;
    border-top-width: 1px;
    border-right-width: 1px;
    border-bottom-width: 1px;
    border-left-width: 1px;
    border-top-color: #ccc;
    border-right-color: #ccc;
    border-bottom-color: #ccc;
    border-left-color: #ccc;
    #nav li a:hover {
    color: #73B5FD;
    background-color: #f2f2f2;
    font-weight: bold;
    text-decoration: none;

    #nav ul {
    position: absolute;
    display: none;
    z-index: 999;
    background-color: #f2f2f2;
    border: 1px solid #cecece;
    #nav ul li a {
    width: auto;
    color: #2350b0;
    font-weight: normal;
    #nav li:hover ul {
    display: block;
    background-color: #f2f2f2;
    What am I missing?

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