[resolved] CSS (4 posts)

  1. Archie22is
    Posted 3 years ago #

    Hi guys,

    I am using wp_list_categories to return a list of categories as a menu. Everything works fine and my html looks like this:

    <ul class="footer-cats">
    <li class="cat-item cat-item-87"><a href=#">Cat1</a></li>
    <li class="cat-item cat-item-39"><a href=#">Cat3</a></li>
    <li class="cat-item cat-item-1"><a href=#">Cat3</a></li>
    <li class="cat-item cat-item-61 current-cat"><a href=#">Cat4</a></li>
    <li class="cat-item cat-item-63"><a href=#">Cat5</a></li>

    However when ever I use Firebug to get the properties for the active / selected cat, I can't seem to style it.

    I can use .current-cat to style, but that will affect the categories used in the menu. How will I reference the footer cats differently to the header cats in this instance?

  2. Michael
    Forum Moderator
    Posted 3 years ago #

    .footer-cats .current-cat a { ... }

    it is not part of this forum to teach fundamental css;
    for those css questions, you might better ask as a css forum like http://csscreator.com/forum
    or check css tutorials like http://www.w3schools.com/css/

  3. Archie22is
    Posted 3 years ago #

    @Alchmyth... I know. I tried that earlier and it did not work.

    Many thanks anyway! I just thought there was something I was doing wrong and wanted "second eyes" :-)

  4. Archie22is
    Posted 3 years ago #

    /* active current category on footer */
    ul.footer-cats li.current-cat a{
    	color: #fff;

    For anyone... should they ever need it

Topic Closed

This topic has been closed to new replies.

About this Topic