--- loncom/interface/lonannounce.pm 2003/05/23 16:14:33 1.12
+++ loncom/interface/lonannounce.pm 2003/06/18 20:06:29 1.15
@@ -1,7 +1,7 @@
# The LearningOnline Network
# Announce
#
-# $Id: lonannounce.pm,v 1.12 2003/05/23 16:14:33 www Exp $
+# $Id: lonannounce.pm,v 1.15 2003/06/18 20:06:29 www Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -32,6 +32,7 @@ use strict;
use Apache::Constants qw(:common);
use Apache::loncommon;
use Apache::lonhtmlcommon();
+use HTML::Entities();
my %todayhash;
@@ -88,6 +89,8 @@ sub normalcell {
$end.'">';
}
}
+ $fullmsg=&HTML::Entities::encode($fullmsg,'<>&"\'');
+ $fullmsg=~s/&/\\&/g;
$output.=''.
substr($msg,0,20).'...
';
}
@@ -108,6 +111,8 @@ sub plaincell {
my $msg=join('@',@msg);
my $fullmsg=$ENV{'course.'.$courseid.'.description'}.
', '.localtime($start).' - '.localtime($end).': '.$msg;
+ $fullmsg=&HTML::Entities::encode($fullmsg,'<>&"\'');
+ $fullmsg=~s/&/\\&/g;
$output.=''.
substr($msg,0,40).'...
';
}
@@ -263,9 +268,18 @@ ENDDOCUMENT
my ($pm,$py,$fm,$fy)=($month-1,$year,$month+1,$year);
if ($pm<1) { ($pm,$py)=(12,$year-1); }
if ($fm>12){ ($fm,$fy)=(1,$year+1); }
+
$r->print('