Viewing 4 replies - 1 through 4 (of 4 total)
  • i have the feeling, the problem lies with the id names:
    https://stackoverflow.com/questions/448981/what-characters-are-valid-in-css-class-names

    having a dot in the id names seems to be invalid – try renaming them using an underscore or hyphen.

    also, if i look at your code, the output seems to something like:

    <div id="menu">
    
    <li id="current.home">
    
    <li>
    
    <li>
    
    <li>
    
    <!--<?php wp_list_pages('title_li=&depth=-1&sort_column=menu_order'); ?>--> 
    
    </div>

    does that make sense (?)
    and, shouldn’t it be wrapped in <ul> tags?

    Thread Starter katemgilbert

    (@katemgilbert)

    Thanks, @alychmyth. I switched the dots to dashes, and it works, but presented a new problem.

    Now, it shows the active state while on current page, but ALSO the inactive state. The two icons appear on top of each other.

    I checked my code and I don’t have any other calls to active. Does anyone know how I can fix this?

    Site: karminmusic.com

    #current_see a.see {
    
        background-image: url("https://karminmusic.com/wordpress/wp-content/uploads/2010/03/see.png");
    
    	background-repeat:no-repeat;
    
    	}
    Thread Starter katemgilbert

    (@katemgilbert)

    Thanks, but that didn’t work. It reverted back to showing no current.

    I am wondering if it has something to do with adding another conditional command?

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Dynamic Menu Highlighting with different li classes’ is closed to new replies.