New release of Date_Holidays PEAR package.

Date_Holidays 0.17.2 was released today; with two new drivers and some bug fixes!

Date_Holidays is a PEAR package for PHP that is used for determining whether a specific date is a [public] holiday in some specified country, listing all such holidays and for these reasons is a useful component for scheduling applications.

This is driver based, one per country.
Currently there are drivers for: Austria, Denmark, England & Wales, Germany, Ireland, The Netherlands (new) , Norway (new), Slovenia, Sweden and the USA.

There are also drivers for Christian and Jewish holidays along with special ‘UN’ celebrated days such as “World Health Day”.

It’s very easy to write new drivers for Date_Holidays, heck I wrote the Ireland driver ;-) So if you’ve noticed there is no driver for where you are I’d recommend that you do so.

6 Responses to “New release of Date_Holidays PEAR package.”

  1. Adam says:

    Oh how nice! Though it doesn’t support it for the country I would need it for :-( !

  2. Ken Guest says:

    What country do you need it for Adam? It really isn’t that difficult to develop a driver – don’t hesitate to ask for help if you feel you need to ;-)

  3. [...] Ken Guest’s online diary Ken Guest’s online diary « New release of Date_Holidays PEAR package. [...]

  4. Luke Welling says:

    Some countries (such as Australia) are less convenient and have different holiday dates in different states.

  5. Ken Guest says:

    Hi Luke,
    The best approach for solving the issue where one territory/region celebrates, using the Australian example here, Labour Day on a different date than the others is to have regional drivers based on and inheriting from a country specific driver.
    This is how we manage calculating religious holidays: we have a driver named Date_Holidays_Driver_Christian which the country drivers inherit from so the inheriting classes don’t have to recalculate the dates of ‘movable feasts’.

    If this were a scenario where some regions celebrate more holidays than others there is a filter pattern that could be used to filter out, or allow in, regional holidays. This is how we manage the holidays in various German states where some, Berlin for example, don’t recognise as many as the others.

    hope this helps ;-)

  6. Ken/Adam,
    Remind me to crack open the dusty Australian public holidays stuff I have floating around at work and get it out into this package.