Dec 23 2007

New version (v2.0) of calendar.class.php now available!

A new version of my php calendar class is now available for download. This new version adds localization and the ability to mark dates that have passed. The download also now includes an examples directory with 8 demonstrations of using the class in various ways. A basic CSS file is also included with the examples as well.

Read the rest of this entry »

Sep 21 2007

Generating a ‘year-at-a-time’ calendar with calendar.class.php

In the previous post announcing the release of calendar.class.php I gave a quick example of how the class could be used to easily output multiple months. That example showed an interface made up of the previous, current and next month. Generating a full year at a time is just as easy to accomplish using a simple for loop. Here’s how…

Read the rest of this entry »

Sep 18 2007

calendar.class.php v1 released

As work progresses on the firepaper project, I found myself in need of a solid PHP class to generate calendar interfaces for things like picking dates for reviewing logged time, scheduling tasks, etc. I looked around for a while at how others were dealing with creating calendar displays and wasn’t satisfied with what I found.

A lot of the examples I found used mathematic calculations to get the days to line up on the proper day of the week and fall into the correct weeks (rows of the table). This seems unnecessary considering PHP’s date function provides everything needed to do the job. In addition I wanted the output to be semantically meaningful, easily styled and of course valid XHTML 1.0 Strict. So, I created my own calendar creation class, calendar.class.php, and I’m releasing it into the wild under a Creative Commons Attribution-Share Alike 3.0 License.

Read the rest of this entry »