--- loncom/interface/lonsyllabus.pm 2006/03/07 21:36:20 1.47 +++ loncom/interface/lonsyllabus.pm 2010/03/03 21:33:15 1.107 @@ -1,7 +1,7 @@ # The LearningOnline Network # Syllabus # -# $Id: lonsyllabus.pm,v 1.47 2006/03/07 21:36:20 www Exp $ +# $Id: lonsyllabus.pm,v 1.107 2010/03/03 21:33:15 droeschl Exp $ # # Copyright Michigan State University Board of Trustees # @@ -29,6 +29,7 @@ package Apache::lonsyllabus; use strict; +use Apache::lontemplate; use Apache::Constants qw(:common); use Apache::loncommon; use Apache::lonnet; @@ -38,6 +39,7 @@ use Apache::lonannounce; use Apache::lonlocal; use Apache::lonhtmlcommon; use Apache::lonspeller(); +use HTML::Entities(); sub handler { my $r = shift; @@ -50,82 +52,31 @@ sub handler { my (undef,undef,$cdom,$cnum)=split(/\//,$r->uri); # ------------------------------------------------------------ Get query string &Apache::loncommon::get_unprocessed_cgi - ($ENV{'QUERY_STRING'},['forcestudent','register','forceedit','wrapperdisplay']); + ($ENV{'QUERY_STRING'},['forcestudent','register','forceedit']); # ----------------------------------------------------- Is this even a course? my $homeserver=&Apache::lonnet::homeserver($cnum,$cdom); if ($homeserver eq 'no_host') { &Apache::loncommon::content_type($r,'text/html'); $r->send_http_header; - $r->print('
'.&mt('No syllabus available').''); + &Apache::loncommon::simple_error_page($r,'No syllabus available', + 'No syllabus available'); return OK; } # ------------------------------------- There is such a course, get environment my %courseenv=&Apache::lonnet::dump('environment',$cdom,$cnum); # ------------------------------------------------------------ Print the screen - my $feedurl='http://'.$ENV{'HTTP_HOST'}.'/public/'.$cdom.'/'.$cnum.'/Course_Announcements.rss'; - if ($target ne 'tex') { - my $html=&Apache::lonxml::xmlbegin(); - $r->print(<