Current Class in Sidebar (5 posts)

  1. vince23
    Posted 3 years ago #

    Hey guys,

    I ve created a sidebar with some linked sites (using the text widget) and would like to create a "current class" to mark the current site.
    How can I do this ?

    Thanks in advance,


  2. kjodle
    Posted 3 years ago #

    <a class="current_class" href="http://example.com/">Link text here</a>

    In stylesheet:

    .current_class {style info here;}

    I'm not quite sure what you mean by "current site", however.

  3. vince23
    Posted 3 years ago #

    I mean a class that indicates on which site Im currently on (by color change of a link).

    You did it manually in your example.

    I want the class to appear automatically and style it in CSS.

    Or is there no automatically created "current"-class in the sidebar widget ?

  4. vjpo
    Posted 3 years ago #

  5. kjodle
    Posted 3 years ago #

    Do you mean "site" or "page"? The latter doesn't mean anything in this case. If you mean "page" then this can be accomplished, but you will need to install a PHP widget and use that instead of the text widget.

Topic Closed

This topic has been closed to new replies.

About this Topic


No tags yet.