Date::Holidays::EnglandWales - Determines bank holidays
use Date::Holidays::EnglandWales; my ($year, $month, $day) = (localtime)[ 5, 4, 3 ]; $year += 1900; $month += 1; my $isodate = "$year-$month-$day"; print "It's a bank holiday" if is_holiday($year, $month, $day); print "Sleep in late!" if Date::Holidays::EnglandWales->is_holiday($isodate);
Date::Holidays::EnglandWales returns true is a given date is a bank holiday in England and wales.
The date can be passed as year, month, day or as an ISO formatted date.
This module uses a simple set of rules to determine whether a date is a holiday rather than a static list. This means it isn't limited to just the next few years and wont require maintainance unless the rules are changed.
It knows about the proposed bank holiday for the Queen's Diamond Jubilee.
This module uses the following modules which you can get from CPAN.
Bank Holidays in England and Wales are determined by the Banking and Financial Dealings Act 1971 and by Royal Proclamation. This means that it is possible that they may change from year to year although in practice this does not happen.
If you need to be absolutely sure about a date check with the DTI whose website is http://www.dti.gov.uk/
Jason Clifford, <email@example.com>
Copyright (C) 2010 by Jason Clifford
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself. That means either the Artistic License or the GNU GPL version 2 or later.