List/Latest Posts in Category ID WordPress Plugin

This is my new simple WordPress plugin that allows you to list: (1) the latest 5 or 7 posts in a category by the category ID, (2) all posts in the category by category ID, and (3) all posts with their excerpts in the category by category ID.

Plugin Concepts

Well, before writing this plugin, I was looking for a plugin that can list the latest post in category, as well as all the posts in the category (with and without the post excerpt). Mainly, I just want to use the listing of all posts + excerpts in category ID function, so I can use it to list all the posts + excerpt as a CATEGORY TYPE II – according to my SEOed site architectural blueprint on link/page-rank distribution. (CATEGORY TYPE I is the default WordPress category.php page that usually list the latest 10 posts (configurable in the “Options => Reading” admin area).

Anyway, because I could not find a way to ‘automatically’ create these CATEGORY TYPE II pages with all its posts and post excerpts, I had adapted another solution to have an option that let the WordPress admin choose “the Number of Posts to show per Category page” in the Best WordPress Template’s “Presentation => Entry” configuration back-end.

Plugin Features

Nevertheless, I had included this plugin in the downloads of the Best WordPress Template + plugins package, because some of you may want to use the default WordPress category page and could use this plugin to create the CATEGORY TYPE II pages to display all the category’s posts and post excerpts => so you can spread the link-love/link-power evenly to all the posts.

Also, there are 2 functions that you can use to display the “Latest Post from Category (ID)” in this plugin, which will be discussed in the “Plugin Usage” section below.

Plugin To-Do List

  1. Use Wordpress Codex API instead of SELECT database.
  2. Add parameter(s) so user can choose the # of posts in the category by category ID to display along with optional post excerpts.

Plugin Installation

Installation is like any WordPress plugin:

1. Download the Best WordPress Template + plugins package
2. Unzip
3. Upload posts-in-category.php to wp-content/plugins on your server
4. Activate the plugin
5. Use the output functions (see “Plugin Usage” below) in your template or sidebar widgets if you’re using PHP widgets.

You can find full details of installing a plugin on the how to install a WordPress plugin page.

Plugin Usage

There are 4 output php functions that you can use:

  • <?php posts_in_cat($catID) ?> = this php function will output a list of all posts wrapped in the <li> tags in the specified category ID (replace $catID with the category ID):

<li><a href=”Post1-Permalink-URL” title=”Post-Title”>Post-Title</a></li>

<li><a href=”Post2-Permalink-URL” title=”Post2-Title”>Post2-Title</a> </li>…

  • <?php excerpt_posts_in_cat($catID) ?> = this php function will output a list of all posts and post excerpts wrapped in the <li> tags in the specified category ID (replace $catID with the category ID):

<li><a href=”Post1-Permalink-URL” title=”Post-Title”>Post-Title</a> – Post1 Excerpt</li>

<li><a href=”Post2-Permalink-URL” title=”Post2-Title”>Post2-Title</a> – Post2 Excerpt</li> …

  • <?php latest_5_in_cat($catID) ?> = this php function will output a list of the latest 7 posts wrapped in the <li> tags in the specified category ID (replace $catID with the category ID):

<li><a href=”Post1-Permalink-URL” title=”Post-Title”>Post-Title</a></li>

<li><a href=”Post2-Permalink-URL” title=”Post2-Title”>Post2-Title</a> </li>…

  • <?php latest_7_in_cat($catID) ?> = this php function will output a list of the latest 7 posts wrapped in the <li> tags in the specified category ID (replace $catID with the category ID):

<li><a href=”Post1-Permalink-URL” title=”Post-Title”>Post-Title</a></li>

<li><a href=”Post2-Permalink-URL” title=”Post2-Title”>Post2-Title</a> </li>…

Discuss this in the forum ยป



If you like "List/Latest Posts in Category ID WordPress Plugin,"
please consider linking to this page:

2 Comments to “List/Latest Posts in Category ID WordPress Plugin” »
  1. Avatar
    May 18th, 2008 at 3:56 pm
    Fahd Murtaza wrote:

    Can’t find the link to download.

    Reply to this comment »
  2. Avatar
    August 4th, 2008 at 8:17 pm
    mas wrote:

    is is for wordpress 2.6 ? and whereis the download link?
    Thanks

    Reply to this comment »
Leave a Comment

Sorry, you must be logged in to post a comment. Login » || Register »

« Previous
« Bread Crumb Navigation for Best WordPress Template | Up Top | Best Wordpress Template 2.0 – 2.3.2 Updates II »
HELP & SUPPORT QUESTIONS

Please post all the support or any other questions in the forums.

Thank you!

P.S. For other support, please use the Ticket Support system (I usually do not do email support).
Latest Comments
chen123: Activity is the only timberland boots uk road to knowledge .A free timberland boot man obtains knowledge...
haber: very nice, but my website was done with joomla :( thanks
data: looks like a great idea, i’m looking for a widget enabled footer-sidebar, but i dont understand, does it...
mas: is is for wordpress 2.6 ? and whereis the download link? Thanks
Fahd Murtaza: Can’t find the link to download.