WordPress.org

Ready to get started?Download WordPress

Forums

WordPress Popular Posts
[resolved] how to exclude categories (18 posts)

  1. globalreporter
    Member
    Posted 2 years ago #

    In the widget I see the "Exclude category" option but I cannot find any place were I can type the IDs to exclude. Please help!

    http://wordpress.org/extend/plugins/wordpress-popular-posts/

  2. Héctor Cabrera
    Member
    Plugin Author

    Posted 2 years ago #

    Hi globalreporter,

    You need to tick the option and save first in order to see the input field.

  3. globalreporter
    Member
    Posted 2 years ago #

    Thanks. I tired. Now I can choose the categories to exclude. But I cannot exclude different different categories for each widget. When I exclude a category for the 1st widget, the same category is excluded for all widgets. Is it your plugin suitable for multi-widget use?

  4. Héctor Cabrera
    Member
    Plugin Author

    Posted 2 years ago #

    Yes, it should allow you to set different categories on each widget. I just tested and added different categories on two separate widgets, both kept their configurations after saving changes.

  5. ruzicic
    Member
    Posted 1 year ago #

    Do you know how can I exclude categories if im using php code in my template file?
    <? echo get_mostpopular('range="weekly"&order_by="views"&pages=0&stats_views=0&stats_comments=0&thumbnail_width=40&thumbnail_height=40&limit=7'); ?>

    Maybe exclude=ID?

  6. drogbadvc
    Member
    Posted 1 year ago #

    Hello, I'm French

    Example : <?php if (function_exists('wpp_get_mostpopular')) wpp_get_mostpopular("range=all-time&order_by=views&limit=5&cats_to_exclude=5,6,7"); ?>

    Code exclude categories : &cats_to_exclude=

  7. markross1967
    Member
    Posted 1 year ago #

    Hi,
    This is a GREAT plugin, thank you!

    The exclude category option works very well. I wish there was an include (only) option, as well. I would like to a a WP Popular Post Widget that only shows the results of one category.

    Is that possible?

    Thank you.

  8. magician1111
    Member
    Posted 1 year ago #

    Pardon me for not understanding. Please help. What do you mean "tick the option first..."?

    Also, in my dashboard when I go to Post Categories, none of the Categories have any numbers or IDs as you call them. I assumed that typing in the blank labeled "Category(ies) ID(s):" the number with a minus sign in front of it would exclude that category. Since I have 24 Post Categories on my blog, I assume that the fourth one is number 4. I typed -4 in the blank and your plugin still does not exclude that category. I also tried typing in just plain 4. Still doesn't work. Please tell me what I'm doing wrong. I have had this problem since I downloaded your plugin over two years ago. How do I find out what the Category(ies) ID(s) are for any given Post Category? Why doesn't typing that number in the box labeled "Category(ies) ID(s):" eliminate that Category from the post rankings?
    http://landscapephotographyblogger.com/
    I want to exclude the category I call "David's Perspective" from the Most popular posts rankings.

  9. markross1967
    Member
    Posted 1 year ago #

    magician,

    Please consider installing this plug-in:
    WP Show IDs

    After you install it, the category IDs will be shown to the right on each Category, under Categories, in the Dashboard.

  10. markross1967
    Member
    Posted 1 year ago #

  11. Héctor Cabrera
    Member
    Plugin Author

    Posted 1 year ago #

    Hi magician1111,

    This thread is over 7 months old now. Info posted there does not apply to the current version of the plugin. Follow markross1967 instructions to find out the categories' IDs.

    Thanks Mark!

  12. magician1111
    Member
    Posted 1 year ago #

    Thank you so much markross1967 and Hector Cabrera for your help! That worked very well.

  13. markross1967
    Member
    Posted 1 year ago #

    You're welcome magician.

    Glad it worked out well for you. It is a simple, yet very nice, plugin.

  14. thedentalwarrior
    Member
    Posted 1 year ago #

    Hello!

    I'm trying to exclude a category. But, in my widgets area, there is no box or area to exclude a category.

    I found a box under FILTERS. Thinking that this was the place to do it, I put my category ID in that box. But, I found out that makes it so the popular posts for ONLY that category will show.

    In my widget area, there is no place to EXCLUDE a category that I can find. Help! Thanks!

  15. markross67
    Member
    Posted 1 year ago #

    All you need to do to exclude a category, in the Popular Posts widget, is put a (-) minus sign before the category ID.

  16. thedentalwarrior
    Member
    Posted 1 year ago #

    @markross67

    BINGO! Thanks! That did it!

  17. markross67
    Member
    Posted 1 year ago #

    You're welcome! : )

  18. BeenGaming
    Member
    Posted 1 year ago #

    Where exactly is "FILTERS"? I also have nothing in the Widgets page at all, and in the Settings for the plugin, I only have three unhelpful tabs - Stats, FAQ, and Tools - none of which have the box you're talking about.

    Thanks in advance

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic