calendar

NP_Calendar.php

This plugin display a calendar that links to days containing blog items, which similar to the calendar functionality Movable Type and Radio Userland provide.

General Plugin info
Current Version: 0.85
Download: np_calendar_v085.zip
Code: click here
Demo: n/a
Forum Thread: forum here

Installing

  1. Copy the code from above link and save it to NP_Calendar.php
  2. Upload the NP_Calendar.php file into the nucleus plugin directory
  3. Install the plugin from the plugin admin menu
  4. Modify the plugin options
  5. Include <%Calendar%> in your skins where you want the blog item calendar to appear.

Available SkinVars and/or TemplateVars

The plugin can be called in an alternative way:

<%Plugin(Calendar, cat, myblog)%>

cat: either all or limited, “all” shows calendar for all categories, “limited” will shows calendar for only the current category

myblog: short name of the blog to be display, allow one to display a calendar for another blog other than the current blog.

Tips and Tricks

To customize the output, please add similar code to the CSS file

table.calendar {
  font-size: small;
  color: black;
}

tr.calendardateheaders {
  font-size: small;
  color: red;
}

td.days {
  text-align: center;
}

td.today {
  text-align: center;
  color: green;
  background-color: whitesmoke;
}

History

  • v0.2: initial plugin
  • v0.21: added doTemplateVar
  • v0.5: - moved table summary to constructor
  • - date headers now created according to locale
  • v0.51: fixed: calender was not limited to blog
  • v0.6: using options now instead of instance variables to keep options
  • v0.7: dates with future/draft posts are no longer linked
  • v0.71: last table cell was missing
  • v0.72: links to previous/next month added (by Roel)
  • Fixed: “Passing locale category name as string is deprecated” by removing two quotes ;-)
  • v0.73: jhoover fixed the bug that appeared in the monthly archives
  • (showing December 1999 everywhere) when using Fancy URL‘s
  • v0.75: short_open_tags: <? → <?php (karma)
  • v0.76: use sql_table, add supportsFeature, add today highlight, merged w/ XE
  • v0.77: added option to change prev/next month link label
  • added option to change day label
  • added option to start week on Sun (integrated changes from Hop)
  • v0.78: added straight calendar mode (no links)
  • v0.78a: merged gRegor’s category change
  • v0.79: fixed typo
  • v0.79a: disabled prev/next month link if SC mode is enabled
  • v0.80: fixed today highlight bug
  • v0.81: included hcgtv’s improvement
  • v0.81a: typo
  • v0.81b: fixed bug reported by Pieter
  • v0.82: fixed blogname parameter bug reported by Pieter
  • v0.83: no link to future month
  • v0.84: add delim between prev/next month (by cs42)
  • v0.85: added year validation for “today” td

Plugin review

NP_Calendar version 0.85 works with Nucleus CMS version 3.31 - 2007-10-27 ftruscot

 
calendar.txt · Last modified: 2007/10/28 05:17 by ftruscot