Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
  • #3740


    I`m using the light skin for my website. For just one category (gallery) I would love to change to the dark skin.

    I tried conditional tags and was able to change the background color for that one category but couldn`t figure it out how to switch the whole stylesheet.

    Can you help?

    Thanks in advance!



    You could use a conditional tag in header.php to adjust the “skin” (or colour scheme) in use on a specific category.

    Change this:

    $skin = $k_option['general']['skin'] != '' ? $k_option['general']['skin'] : 1;


    if ( is_category('category-slug')) {
    $skin = 4;
    } else {
    $skin = $k_option['general']['skin'] != '' ? $k_option['general']['skin'] : 1;

    You’ll need to update category-slug to the category slug of the gallery category and 4 to the number of the stylesheet you want to use (located in the CSS folder).

    e.g. To use /css/style3.css you’d change 4 to 3

    See the codex for a full list of conditional tags:

    Hope this helps!



    Hi James,

    great – thats exactly what I wanted!

    I still had to chance the conditional tags slightly and now it works like a charm.

    Thanks a lot,



    Glad that James could help you :)

Viewing 4 posts - 1 through 4 (of 4 total)

The topic ‘Change skin for category’ is closed to new replies.