Skip Menu |

This queue is for tickets about the HTML-CalendarMonth CPAN distribution.

Report information
The Basics
Id: 37548
Status: resolved
Priority: 0/
Queue: HTML-CalendarMonth

People
Owner: MSISK [...] cpan.org
Requestors: jm [...] mayfirst.org
Cc:
AdminCc:

Bug Information
Severity: Normal
Broken in: 1.18
Fixed in: 1.20



Subject: Make module more css friendly by default
Thanks for the great work! I have a small patch which I think would improve the module. The default calendar includes attributes likes bgcolor and border which are to my knowledge deprecated (http://www.w3.org/TR/html401/present/graphics.html). This attached patch removes the deprecated atrributes and replaces them with a class attributes.
Subject: CalendarMonth.pm.patch
--- /usr/share/perl5/HTML/CalendarMonth.pm 2008-02-18 15:44:17.000000000 -0500 +++ CalendarMonth.pm 2008-07-08 20:03:49.000000000 -0400 @@ -238,12 +238,9 @@ } # Defaults - $self->table->attr(align => 'center'); - $self->item($self->month)->attr(align => 'left') if $self->head_m; - $self->attr(bgcolor => 'white') unless defined $self->attr('bgcolor'); - $self->attr(border => 1) unless defined $self->attr('border'); - $self->attr(cellspacing => 0) unless defined $self->attr('cellspacing'); - $self->attr(cellpadding => 0) unless defined $self->attr('cellpadding'); + $self->table->attr(class => 'month-calendar-cell'); + $self->item($self->month)->attr(class => 'month-calendar-head') if $self->head_m; + $self->attr(class => 'month-calendar') unless defined $self->attr('class'); $self; }
added in 1.20