Forums

[resolved] CSS for wp_list_pages (3 posts)

  1. Ronin898
    Member
    Posted 3 years ago #

    I have a wp_list_pages() which I need help styling. The class that is returned class="page_item page-item-2 current_page_item"

    In this theme I'm developing, I need to define a separate style for page-item-2, when it is the current page, and when it's not. Which is no big deal, here's the kicker, I need page-item-3, and page-item-3 current_page_item be different than their page-item-2 counterparts.

    Is it possible to do something like this in CSS?

  2. stvwlf
    Member
    Posted 3 years ago #

    Hi

    It won't work reliably in IE6 but in all other browsers you can say

    .page-item-2.current_page_item { }

    That styling will only be applied to things defined with both of those classes. Thus you can do the same with page-item3 also.

  3. Ronin898
    Member
    Posted 3 years ago #

    God bless Microsoft :( Thanks stvwlf

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.