Site logo

Archived topic

how to hide the category for geek theme?

11 replies · Started by jason on December 6, 2022

Viewing posts 1–12 of 12

Hi Jason,

Do you mean to remove the category section from the Geek template?

yes, how to remove one or more categories for geek theme?

Thanks

Leo:

What I need is hige the category, not remove.

Thanks

Jason

Hi Jason,

You can try adding this through Appearance > Customize > Additional CSS

a.gb-button[href="https://thesupplying.com/category/hide/"] {
    display:none;
}

This won't display GB Buttons with this link: https://thesupplying.com/category/hide/

It should work for this link: https://thesupplying.com/few-question-for-geek/#more-2514

For a page like that, you'll need a different CSS. Try adding this:

ul.wp-block-categories-list.wp-block-categories li:has(a[href="https://thesupplying.com/category/hide/"]) {
    display:none;
}

https://thesupplying.com/category/buy-from-china/

Really thanks for the help, how to modify the code to hide another category like the above "buy from china"

ul.wp-block-categories-list.wp-block-categories li:has(a[href="https://thesupplying.com/category/hide/"]) {
display:none;
}

In the code, I'm using the link of the category to hide it. So you can try this:

ul.wp-block-categories-list.wp-block-categories li:has(a[href="https://thesupplying.com/category/buy-from-china/"]) {
    display:none;
}

If you want multiple categories hidden in one code, you can try this instead:

ul.wp-block-categories-list.wp-block-categories li:has(:is(a[href="https://thesupplying.com/category/buy-from-china/"],a[href="https://thesupplying.com/category/hide/"])) {
    display:none;
}

Deeply thanks for your help.

You're welcome, Jason!

This archived topic is closed to new replies.