note
gryphon
<p>Greetings Anonymous Monk,</p>
<p>From what you describe in your post, I think [cpan://HTML::Calender::Simple] would be perfect. The whole $type/$info thing for date events didn't work for me, so I ended up just writing a simple subroutine to handle the link creation myself, then passed that into the daily_info method.</p>
<code>use strict;
use warnings;
use CGI;
use HTML::Calendar::Simple;
my $cgi = CGI->new;
print $cgi->header;
my $cal = HTML::Calendar::Simple->new({
'month' => 6,
'year' => 2005,
});
sub _display_events {
my $events = shift;
return join('<br/>', map {
$cgi->a({ href => $_->[0] }, $_->[1])
} (@{$events}));
}
$cal->daily_info({
'day' => 21,
'events' => _display_events([
['http://perlmonks.org', 'PerlMonks'],
['http://whitepages.com', 'Whitepages']
]),
});
print $cal->calendar_month;
</code>
<!-- Node text goes above. Div tags should contain sig only -->
<div class="pmsig"><div class="pmsig-25626">
<p>[gryphon]<br/>
<small>Whitepages.com Development Manager (DSMS)</small><br/>
<i>code('Perl') || die;</i></p>
</div></div>
468882
468882