[AppWrap-cvs] AppWrap/Apache/AppWrap Calendar.pm,1.6,1.7
Status: Beta
Brought to you by:
planetman
From: <pla...@us...> - 2002-12-08 02:41:45
|
Update of /cvsroot/appwrap/AppWrap/Apache/AppWrap In directory sc8-pr-cvs1:/tmp/cvs-serv29121 Modified Files: Calendar.pm Log Message: Changes for i18n Index: Calendar.pm =================================================================== RCS file: /cvsroot/appwrap/AppWrap/Apache/AppWrap/Calendar.pm,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** Calendar.pm 7 Dec 2002 02:17:07 -0000 1.6 --- Calendar.pm 8 Dec 2002 02:41:41 -0000 1.7 *************** *** 8,11 **** --- 8,13 ---- use strict; + use warnings; + no warnings qw(redefine); use CGI::Carp qw(fatalsToBrowser); use Date::Format qw(time2str); *************** *** 22,28 **** use vars qw($VERSION); ! $Apache::AppWrap::Calendar::VERSION = '0.06'; ############################ ! # 06Nov02. Migrate to CSS-based presentation # 05Nov02. handle HEAD requests ############################ --- 24,31 ---- use vars qw($VERSION); ! $Apache::AppWrap::Calendar::VERSION = '0.08'; ############################ ! # 06Dec02. use warnings pragma ! # 06Dec02. Migrate to CSS-based presentation # 05Nov02. handle HEAD requests ############################ *************** *** 43,46 **** --- 46,63 ---- my $col_order = $opts->{col_order}; + my $msgs = $opts->{display_text}; + $msgs ||= Apache::AppWrap::Subs::get_display_text($opts); + $opts->{display_text} ||= $msgs; + + # titles want to see these vars defined + my $link_vars = Apache::AppWrap::Subs::cclinks($opts); + + my $title = eval $msgs->{title} if $msgs->{title}; + unless ($title) { + $r->log_error("Calendar: no title eval'd: $msgs->{title}"); + return SERVER_ERROR; + } + $opts->{Title} = $title; + my $log = $r->log; # get guery string *************** *** 176,182 **** # might be able to use a pdf maker to print calendars - - my $link_vars = Apache::AppWrap::Subs::cclinks($opts); - $opts->{Title} = 'Calendar of ' . $link_vars->{label}; $opts->{Rows} = \@rows; --- 193,196 ---- |