javascript onClick function not working

on this page One of the navigators "Associated Profession/Therapy" view more link not working while it works on other navigators. The javascript view more function is as below

function ViewMore(spacetId){  
    $("#" + spacetId + " li").each(
        function(){  
            if($(this).children("a").hasClass("showAll"))                
                $(this).css("display", "none");
            else if($(this).children("a").hasClass("showTop"))
                $(this).css("display", "block");
            else                
                $(this).show();                
        }
    );    
    return false;
}

Open in new window


Any ideas how to fix this?
mmalik15Asked:
Who is Participating?
 
leakim971PluritechnicianCommented:
Because the slash it fail : AssociatedProfession / Therapy
The other don't have slash :
AreaofPractice
Location

slash is not a good char inside an ID attribute
0
 
mmalik15Author Commented:
thanks for the comment.

I can't change the slash in the navigator but can modify the script if this can be tackled.
0
 
leakim971PluritechnicianCommented:
Remove the slash the same  way you removed the spaces for the others links.
Yes the same way
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.