version 1.19, 2003/09/03 01:53:46
|
version 1.20, 2003/09/17 19:45:39
|
Line 32 use strict;
|
Line 32 use strict;
|
use Apache::Constants qw(:common); |
use Apache::Constants qw(:common); |
use Apache::loncommon; |
use Apache::loncommon; |
use Apache::lonhtmlcommon(); |
use Apache::lonhtmlcommon(); |
|
use Apache::lonlocal; |
use HTML::Entities(); |
use HTML::Entities(); |
|
|
my %todayhash; |
my %todayhash; |
Line 367 SERVERANNOUNCE
|
Line 368 SERVERANNOUNCE
|
if ($pm<1) { ($pm,$py)=(12,$year-1); } |
if ($pm<1) { ($pm,$py)=(12,$year-1); } |
if ($fm>12){ ($fm,$fy)=(1,$year+1); } |
if ($fm>12){ ($fm,$fy)=(1,$year+1); } |
|
|
$r->print('<h1>'.('','January','February','March','April','May', |
$r->print('<h1>'.('',&mt('January'),&mt('February'),&mt('March'), |
'June','July','August','September','October', |
&mt('April'),&mt('May'), |
'November','December')[$month].' '.$year.'</h1>'); |
&mt('June'),&mt('July'),&mt('August'), |
|
&mt('September'),&mt('October'), |
|
&mt('November'),&mt('December'))[$month].' '. |
|
$year.'</h1>'); |
# Reached the end of times, give up |
# Reached the end of times, give up |
if (($year<1970) || ($year>2037)) { |
if (($year<1970) || ($year>2037)) { |
$r->print('<h3>No calendar available for this date.</h3>'. |
$r->print('<h3>No calendar available for this date.</h3>'. |
Line 379 SERVERANNOUNCE
|
Line 383 SERVERANNOUNCE
|
} |
} |
$r->print( |
$r->print( |
'<a href="/adm/announcements?month='.$pm.'&year='.$py. |
'<a href="/adm/announcements?month='.$pm.'&year='.$py. |
($pickdatemode?$pickinfo:'').'">Previous Month</a> '. |
($pickdatemode?$pickinfo:'').'">'.&mt('Previous Month').'</a> '. |
'<a href="/adm/announcements?month='.$fm.'&year='.$fy. |
'<a href="/adm/announcements?month='.$fm.'&year='.$fy. |
($pickdatemode?$pickinfo:'').'">Next Month</a>'. |
($pickdatemode?$pickinfo:'').'">'.&mt('Next Month').'</a>'. |
' <a href="/adm/announcements?month='.$todayhash{'month'}. |
' <a href="/adm/announcements?month='.$todayhash{'month'}. |
'&year='.$todayhash{'year'}. |
'&year='.$todayhash{'year'}. |
($pickdatemode?$pickinfo:'').'">Current Month</a><p>'. |
($pickdatemode?$pickinfo:'').'">'.&mt('Current Month').'</a><p>'. |
'<table border="2" cols="7" rows="5"><tr><th>'. |
'<table border="2" cols="7" rows="5"><tr><th>'. |
&tfont('Sun') |
&tfont(&mt('Sun')) |
.'</th><th>'. |
.'</th><th>'. |
&tfont('Mon') |
&tfont(&mt('Mon')) |
.'</th><th>'. |
.'</th><th>'. |
&tfont('Tue') |
&tfont(&mt('Tue')) |
.'</th><th>'. |
.'</th><th>'. |
&tfont('Wed') |
&tfont(&mt('Wed')) |
.'</th><th>'. |
.'</th><th>'. |
&tfont('Thu') |
&tfont(&mt('Thu')) |
.'</th><th>'. |
.'</th><th>'. |
&tfont('Fri') |
&tfont(&mt('Fri')) |
.'</th><th>'. |
.'</th><th>'. |
&tfont('Sat') |
&tfont(&mt('Sat')) |
.'</th></tr>'); |
.'</th></tr>'); |
|
|
my $tk=&Apache::loncommon::maketime(%firstday); |
my $tk=&Apache::loncommon::maketime(%firstday); |
Line 432 SERVERANNOUNCE
|
Line 436 SERVERANNOUNCE
|
if ($allowed) { $r->print('<input type="button" onClick="removesub()" value="Remove Checked Entries"></form>'); } |
if ($allowed) { $r->print('<input type="button" onClick="removesub()" value="Remove Checked Entries"></form>'); } |
$r->print('<p>'. |
$r->print('<p>'. |
'<a href="/adm/announcements?month='.$pm.'&year='.$py. |
'<a href="/adm/announcements?month='.$pm.'&year='.$py. |
($pickdatemode?$pickinfo:'').'">Previous Month</a> '. |
($pickdatemode?$pickinfo:'').'">'.&mt('Previous Month').'</a> '. |
'<a href="/adm/announcements?month='.$fm.'&year='.$fy. |
'<a href="/adm/announcements?month='.$fm.'&year='.$fy. |
($pickdatemode?$pickinfo:'').'">Next Month</a>'. |
($pickdatemode?$pickinfo:'').'">'.&mt('Next Month').'</a>'. |
' <a href="/adm/announcements?month='.$todayhash{'month'}. |
' <a href="/adm/announcements?month='.$todayhash{'month'}. |
'&year='.$todayhash{'year'}. |
'&year='.$todayhash{'year'}. |
($pickdatemode?$pickinfo:'').'">Current Month</a></p>'. |
($pickdatemode?$pickinfo:'').'">'.&mt('Current Month').'</a></p>'. |
($pickdatemode?'</font>':''). |
($pickdatemode?'</font>':''). |
'</body></html>'); |
'</body></html>'); |
return OK; |
return OK; |