Forums

Removing Posts from specific category in 2010 widgets (6 posts)

  1. wyndom
    Member
    Posted 1 year ago #

    I am using a mod'ed version of 2010 on WP 3.0.1
    I would like to exclude all of the posts from cat 4 and 5 from the widgets/sidebars in Twenty Ten, but ideally I'd like to keep the functionality of the sidebars intact (eg Drag and Drop placement etc - no static sidebars).

    I have successfully removed all posts (from cat 4&5) from the 'blog' page and 'archives' page by using query_posts("cat=-4, -5");

    Now I need to include something similar into:
    Recent Posts - Widget
    Archives - Widget -> Need correct count assoiciated with this
    Categories - Widget
    Recent Posts - Footer Widget

    Unfortunately I don't really know where to look for the code that populates these things. Any help would be greatly appreciated.

  2. dskallman
    Member
    Posted 1 year ago #

    Have you tried looking through plugins for widgets with more options that allow this?

    There's also this plugin:
    http://wordpress.org/extend/plugins/simply-exclude/

  3. wyndom
    Member
    Posted 1 year ago #

    Thank you dskallman
    I was able to remove the two categories I wanted hidden using simply-exclude, but that did not hide posts from those two categories that I also wanted hidden. So using simply-exclude along with http://wordpress.org/extend/plugins/mcatfilter/
    I was able to hide the categories and the posts from all 2010 widgets.
    thanks!

  4. wyndom
    Member
    Posted 1 year ago #

    My archive post counts are incorrect still, but I'll probably just turn that off as its not really important for this site.

  5. manojonwp
    Member
    Posted 1 year ago #

    Hello wyndom,

    I'm using Twenty Ten 1.1 theme with WordPress 3.0.1.

    I'm trying to exclude some posts from blog page. So I created a category and added those posts their and used the same method as you to remove them using query_posts("cat=-5").

    It does remove posts, but then when I click older posts at the bottom of the page, it keeps repeating the same 10 post. I have set the number of posts to 10 using settings.

    Maybe I haven't inserted the code in its proper place.

    Any help would be very useful before I lost my mind.

    Thanks.

  6. manojonwp
    Member
    Posted 1 year ago #

    Thanks for trying to help. I tackled this problem by creating a child theme for twenty ten and by re adding the code.

Topic Closed

This topic has been closed to new replies.

About this Topic