previousposts

NP_PreviousPosts.php

NP_PreviousPosts adds a Blogger-like feature that shows the latest X items posted *before* the current item.

General Plugin info
Current Version: 0.4
Download: here (v0.4), outdated (v0.2)
Forum Thread: http://forum.nucleuscms.org/viewtopic.php?t=5211
Author: moraes, mod by PiyoPiyoNaku

Feedback

Post bug reports and suggestions here at the Nucleus forum: http://forum.nucleuscms.org/viewtopic.php?t=5211

Upgrading

  1. Uninstall your previous NP_PreviousPosts installation
  2. Replace your old NP_PreviousPosts file with the new file from the zip content
  3. Reinstall this plugin from your Nucleus admin area

Instructions

  1. Upload NP_PreviousPosts.php to your plugins directory.
  2. Install the plugin.
  3. Put <%PreviousPosts(7,1,current,current)%> in your short or full templates. The parameters are explained below:
  • 7 → the number of items to show (optional, default is 5)
  • 1 → limit the list to items from a given blog (optional, default is the current blog)
  • current → can be either catid, category name, or current (optional, default is from all category)
  • current → can be either memberid or current (optional, default is from all member)
  • latest → to behave like NP_LatestPosts, even if used on the index skin (optional)
  • 2 → use the second display formatting (optional, default is the first display formatting)

History

  • Version 0.4 - mod by PiyoPiyoNaku, 9-Mar-2007
    • better error handling if using current in index skin part - show all
    • slight bug fix / code cleaning regarding compatibility with NP_Alias [Must use the new NP_Alias v1.3 to make the compatibility works]
    • better error handling if category name contains error - show all
    • 5th skinvar parameter - latest will display PreviousPosts like LatestPosts, even if its on the item skin part
    • 6th skinvar parameter - so the user can choose between 2 display formatting
    • if used in member page skin, if using current for 4th skinvar parameter, will behave like NP_MemberItems
  • Version 0.3 - mod by PiyoPiyoNaku, 8-Mar-2007
    • slight bug fix: addition of idraft=0 so it won’t show draft items
    • use of sql_query()
    • can show the number comments for each previous item displayed
    • can change the display formatting through plugin options
    • able to display date (with date formatting) and author
    • compatibility with NP_Alias, will display alias rather than username if alias exists
    • 3rd skinvar parameter - can be either catid, category name, or current
    • 4th skinvar parameter - can be either memberid or current
  • Version 0.1 - november 21, 2004. Initial version.
 
previousposts.txt · Last modified: 2009/07/01 00:10 by ftruscot