WordPress.org

Forums

Styling Navigation menu (6 posts)

  1. germij
    Member
    Posted 4 years ago #

    I need to style my nav div from my blog motiveocean.com. I want to make it look like a horizontal menu and I need help with css.

  2. ericdaams
    Member
    Posted 4 years ago #

    First of all, you need to make the list items display inline (side by side, rather than top to bottom). To do so, add this rule to your stylesheet;

    #navmenu li {display:inline;}

  3. germij
    Member
    Posted 4 years ago #

    This is how I have it in css.
    #navmenu li {display: inline; }

    But the menu looks like it is style as a vertical menu

  4. for the css of a horizontal menu, check:
    http://codex.wordpress.org/Creating_Horizontal_Menus

    if you are stuck with it, post a link to your site

  5. germij
    Member
    Posted 4 years ago #

  6. changing this line in style.css might help:
    from this

    #navmenu ul {margin: 0; padding: 0;
    	list-style-type: none; list-style-image: none; }

    to this

    #navmenu ul {margin: 5px 0; padding: 0; display:inline-block;
    	list-style-type: none; list-style-image: none; }

    and then, in header.php, change the 'wp_list_categories()' to
    wp_list_categories('title_li=');
    to suppress the word 'category' in the list.

    http://codex.wordpress.org/Template_Tags/wp_list_categories

Topic Closed

This topic has been closed to new replies.

About this Topic