Calendar
pear.php.net
A package for building Calendar data structures (irrespective of output)
Calendar provides an API for building Calendar data structures. Using the simple iterator and it's "query" API, a user interface can easily be built on top of the calendar data structure, at the same time easily connecting it to some kind of underlying data store, where "event" information is being held.

It provides different calculation "engines" the default being based on Unix timestamps (offering fastest performance) with an alternative using PEAR::Date which extends the calendar past the limitations of Unix timestamps. Other engines should be implementable for other types of calendar (e.g. a Chinese Calendar based on lunar cycles).
Harry Fuecks
hfuecks
hfuecks@phppatterns.com yes
Lorenzo Alberton
quipo
l.alberton@quipo.it yes
Greg Beaver
cellog
greg@chiaraquartet.net yes
2010-06-24
13:54:05
0.5.5
0.5.5
beta
beta
PHP
* fixed bug #17182: fixed Calendar_Month_Weeks' empty day handling (bug introduced in v.0.5.4) * PHP5 fixes
5.0.0
1.5.0
Date
pear.php.net
0.5.4
0.5.4
beta
beta
2008-12-12
PHP
* fixed return by reference NOTICE in Decorator * fixed bug #8758: fixed Calendar_Week::thisYear() according the ISO-8601 standard * fixed bug #12542: Calendar_Util_Textual::orderedWeekdays() doesn't consider $firstDay * added new tests and fixed test to consider the CALENDAR_FIRST_DAY_OF_WEEK constant * fixed getWeekNInYear() in the PearDate engine with new Date package * request #2642: added Calendar::isToday() method * switched to package.xml v.2 * updated header comment blocks according to the Coding Standards
0.5.3
0.5.3
beta
beta
2005-10-22
PHP
* fixed bug #3073, Calendar_Month_Weekdays: invalid empty days at year change * fixed bug #3445, thisWeek('n_in_month') off by one in some cases * use CALENDAR_FIRST_DAY_OF_WEEK constant throughout the package * fixed return by reference NOTICEs * added new tests
0.5.2
0.5.2
beta
beta
2004-08-03
PHP
* Small refactoring in the date engines to significantly reduce the number of date() calls * make url default separator xhtml compliant (& => &amp;) * fix bug #1798 with week selection * fix bug #1995: thisWeek, prevWeek, nextWeek were not affected when a new timestamp was set (thanks to johnschaefer at gmx dot de) * fix bug in return value from Calendar_Week::thisWeek and n_in_month * getMinYears() returned 1970 on all platforms (thanks to Andy Crain) * added some new examples * Moved logic from Calendar_Decorator_Uri and Calendar_Decorator_Textual to Calendar_Util_Uri and Calendar_Util_Textual (BC preserved) - offers better performance, reducing number of decorators required * extended engine interface for week related methods to meet rare use cases with (not yet implemented) calendar engines
0.5.1
0.5.1
beta
beta
2004-05-25
PHP
* Fixed bug in Calendar_Week::setSelection(): the "selected" property was set, but not the decorated object. * Fixed bug in Calendar_Month_[Weekdays|Weeks]: the number of empty days at the beginning of the month could be wrong when the adjust() method was called to fix an invalid date.
0.5
0.5
beta
beta
2004-01-29
PHP
* Added new return-value-formats for each [prev|this|next]*() method Allowed formats are: 'int', 'timestamp' , 'array' and 'object'. Returns data of specified type e.g. $Day = $Hour->prevDay('object'); * Added factory for creating calendar objects (in conjunction with above change) * Added decorator to determine the day of the week for any calendar object * Minor bug fix in Decorator
0.4
0.4
beta
beta
2003-11-22
PHP
* Fixed bug in setTimeStamp where year wasn't set * Fixed bugs and changed API for Calendar_Week * Added Calendar::adjust method to adjust invalid dates * Added Calendar_Decorator_Uri to help with building links * Added Calendar_Decorator_Textual to help fetching month and weekday names * Added Calendar_Decorator_Wrapper to help apply decorators to built calendar objects
0.3
0.3
beta
beta
2003-10-30
PHP
* Fixed bugs in Calendar_Validator for day and month ranges * Fixed bug with first day of week as 0 * Modified weeks to extend beyond current month with prevWeek() and nextWeek() * More unit tests
0.2
0.2
beta
beta
2003-10-28
PHP
First release