Category content

Views: 2372 Last modified: July 31st, 2011 Comments: 28

This wordpress plugin (Widget) will be shown as widget when visitors are viewing a single post. Otherwise, it wont be there.
It contains a list of post titles from the same category the visitor is viewing the post from, so the visitor is able to swiftly change post by clicking on the titles shown.
It works fine if the post has been put into multiple category’s.

The widget can be controlled with the following widget options:

  • Title
  • Show widget: categories/single posts/both
  • Show categories: Show the categories after the optional title (Widget title)
  • Amount posts
  • Order on single posts: DESC | ASC
  • Orderby on single posts: Author | Category | Date | ID | Random
  • Order on category pages: DESC | ASC
  • Orderby on category pages: Author | Category | Date | ID | Random
  • Remove/Keep child categories

How to use ?

Just install the plugin as you are used. Go to the admin panel and choose “Widgets” which you can find under “Appearance”. Put the widget into a sidebar and customize the settings!

Version: 0.6.0:

  • Added: Option (Control child cats)

Version: 0.6.1:

  • Fixed: Added title attribute

Version: 0.7.0:

  • Added: Choose where the widget must be shown
  • Added: Separate control for Order & Sort options

Version: 1.1:

  • Fixed: Fixed some minor ugly coding mistakes
  • Added: Added a default class to the list item (category-item)
  • Added: Added a list item class to the current shown post (category-current-item)
  • Fixed: Fixed the issue concering the option which will show the widget on category pages and single posts (didn’t work properly)
Attachments 2 image(s) & 0 video(s) found.
VN:F [1.9.13_1145]
Rating: 10.0/10 (2 votes cast)
VN:F [1.9.13_1145]
Rating: +3 (from 3 votes)
Category content, 10.0 out of 10 based on 2 ratings
    Category content
    Category content
    categorycontent.zip
    3.3 KiB
    189 Downloads
    Details...

    Mail this!

    To: From:Sum {3+5} =  
    1. Hey Kaine,

      Thanks for your comment and interest!

      About your request... All you want to have is an textfield where you can put category ID's which you want to exclude from the widget ?

      Let me know,
      Cheers
    2. Sort of like the above question ^

      I'm looking to exclude a category from this widget entirely. I have a widget that always displays the recent posts from the category, and this widget seems to pull that category even it when it shouldn't. So I'm hoping a full on exclude will work. Any code written up?
    3. I'm glad you like it!
    4. Sorry, I did a mistake with another site. It works! :)
      Thanks for great plugin.
    5. It works great in single site. But since I installed it on multi-sites Wordpress, it's not working anymore. No error, it just doesn't appear.

      Any idea to fix it please?
      Thanks.
    6. @plantprojects...

      Check your email!
    7. Hi Majorfun,

      I'm glad it all worked out for you!
      You can rate this plugin right here
      Category content plugin @ wordpress

      I will add the request of plantproject asap, so you might receive a notice of an update @ your admin panel soon. Don't worry, it is still your version, only you are the first who uses it!

      Cheers
    8. Where do I go to give it all the stars it so deserves?
    9. Forget the previous. I figured it out! It took a few more minutes of quiet desperation. Not only am I proud of myself, I am delighted that the new version actually works. O, 5 stars in deed!
    10. I checked my email. I received the new version. I am looking forward to using it. I still (mea culpa) don't know how to install it. What directory should it be in? I uploaded it to my wp-admin directory, but can't see it. I need help, in deed I do.
    11. @Majorfun - Please check your email. You received a new release which would be the solution to your issue. Please let me know the result.

      @Plantprojects - All you want is a class added to the list item which is currently viewed by the user ? That would be no problem.
      I will look into that today and otherwise tomorrow.

      Cheers
    12. p.s. I appreciate your responsiveness, love the plugin, and look forward to the fix.
    13. This plugin is fantastic. I am using it as a secondary menu and would like to add the functionality of the post title being highlighted in the menu when that post is being displayed.

      How would one go about adding a class to the Category Content link that matches the current page like current_page_item for the WP menu?

      My php skills are pretty basic and I'm having a hard time writing a function to do this. I thought by matching href in the anchor link to the url of the current page I could add a class to the correct title tag to highlight it. My attempts to write the code correctly for this to work have been feeble. Any advice would be much appreciated.
    14. I'm not one of your more technically adept users. If I can access it from the "search plugins" page and then add it like automatically, I'm genius.
    15. I see your issue. You got some time to test a new release ? Can i send it by email ?
    16. Having some trouble - check majorfun.com - when I select a category it lists multiple categories, not just items belonging to category I selected. (most of the entries have multiple categories)
    17. Hi TSG,

      I'm glad you like the widget.. :)

      You can turn off the appended part. Go to your widgets and within this widget there is a option called "show categories". Set this to no.

      Cheers
    18. Hi Lauren,

      Great plugin - saved my bacon this week, thanks!

      I've put the widget in the sidebar and I was hoping that the title field would override any default output? Currently it appends the category name (e.g. "Recent posts in category name") when all I really want is "Recent posts" (I had to add "in" to make a sentence).

      Using v0.7.0, a fresh install of WP and TwentyTen on localhost.

      All the best, Karl
    19. Check your email :)
    20. Oh wow, that would be awesome. I don't know if you want to think about one more feature, but what would be AWESOME is if you can give it the ability to show the post thumbnail if someone chooses to do that. Somethings small - maybe like 35x35 pixels. Please think about it :)
    21. Hi Irsamuel,

      Both your requests could be done. I will look into it next week and update the plugin. I will send you a "test" version by email so you can check the updated plugin.

      Cheers
    22. Hi MrXHellboy,

      First of all, this is a great plugin. Thank you very much for creating it. I have 2 questions for you:

      1. Is there a way to have the header of the widget have custom text, instead of just a listing of the category? For example, I post video entries on my blog. Right now, it shows links to the categories. I would like it to say something like "Other Videos in this category", and not link to the actual category.

      2. Is there a way to also have it show up on the category pages? For example, when someone goes to mydomain.com/category/videos/, it shows the most recent 10 videos in that category. I would like to have it also show the widget in my sidebar then.

      Looking forward to your response.
    23. Hi Kevin,

      1. Which version do you have of this plugin ?
      2. Could you please give me your website so i can see the problem.

      This plugin checks whether your post has been placed into multiple categories. As long as you have no posts, placed @ multiple categories, you can change the above code without any problems.

      However, i will note your comment for future updates if needed.

      Cheers
    24. I needed to remove a duplicate entry from the title tag (had posts in topic1/province and topic2/province), and also wanted to remove the link that would come up in the widget for the current post and added this:


      # override by // kevin to get rid of duplicates
      $CatTitles = get_cat_name($IDS[0]);
      # page to exclude from list in widget by // kevin
      $thePostID = $post->ID;
      # Post arguments
      $args = array('orderby' => strip_tags($instance['orderby']),
      'order' => strip_tags($instance['order']),
      'post_type' => 'any',
      'post_status' => 'publish',
      'numberposts' => strip_tags($instance['amount']),
      'category' => $CatID,
      'exclude' => $thePostID);
    25. Hi Sam,

      I dropped a file in your mailbox. Please replace the current plugin file with the one i just dropped.

      let me know.
      Cheers
    26. exactly - I only want to show posts for the exact sub category I'm reading a post in, not any posts from parent categories.
    27. For my understanding..... You want to exclude the parent category(s) ? The same for child category(s) ?

      Cheers
    28. Hey - this is really a fantastic plugin.

      One thing though - is it possible to configure it so that the widget will only show more posts from the subcategory level?

      For example if I am on a post in /category1/subcategory1/ I only want to show more posts from /subcategory1/, not /category1/ AND /subcategory1/.

      If that would be possible, I think this plugin would be flawless. Thanks again!
    Anything to add ?

        You must be logged in to post a comment.