version 1.50, 2006/03/21 21:50:49
|
version 1.53, 2006/08/01 13:55:07
|
Line 71 sub handler {
|
Line 71 sub handler {
|
if ($target eq 'tex') { |
if ($target eq 'tex') { |
$r->print(&Apache::lonprintout::print_latex_header($env{'form.latex_type'})); |
$r->print(&Apache::lonprintout::print_latex_header($env{'form.latex_type'})); |
} |
} |
# ----------------------------------------------------- Force menu registration |
|
my $addentries=''; |
|
if ($env{'form.register'}) { |
|
$addentries=' onLoad="'.&Apache::lonmenu::loadevents(). |
|
'" onUnload="'.&Apache::lonmenu::unloadevents().'"'; |
|
} |
|
# -------------------------------------------------- Let's see who handles this |
# -------------------------------------------------- Let's see who handles this |
my $externalsyllabus=$courseenv{'externalsyllabus'}; |
my $externalsyllabus=$courseenv{'externalsyllabus'}; |
|
|
Line 120 sub handler {
|
Line 114 sub handler {
|
my $start_page = |
my $start_page = |
&Apache::loncommon::start_page("Syllabus", $rss_link, |
&Apache::loncommon::start_page("Syllabus", $rss_link, |
{'function' => $forcestudent, |
{'function' => $forcestudent, |
'add_entries' => $addentries, |
|
'domain' => $cdom, |
'domain' => $cdom, |
'force_register' => |
'force_register' => |
$env{'form.register'},}); |
$env{'form.register'},}); |
Line 135 sub handler {
|
Line 128 sub handler {
|
my $day = &Apache::lonannounce::showday(time,2, |
my $day = &Apache::lonannounce::showday(time,2, |
&Apache::lonannounce::readcalendar($cdom.'_'.$cnum)); |
&Apache::lonannounce::readcalendar($cdom.'_'.$cnum)); |
if ($target ne 'tex') { |
if ($target ne 'tex') { |
$r->print($day. &Apache::lonrss::advertisefeeds($cnum,$cdom)); |
$r->print($day. &Apache::lonrss::advertisefeeds($cnum,$cdom,$forceedit)); |
} else { |
} else { |
$r->print(&Apache::lonxml::xmlparse($r,'tex',$day)); |
$r->print(&Apache::lonxml::xmlparse($r,'tex',$day)); |
} |
} |
Line 184 sub handler {
|
Line 177 sub handler {
|
# ----------------------------------------------------- Only if not public call |
# ----------------------------------------------------- Only if not public call |
if ($env{'user.environment'}) { |
if ($env{'user.environment'}) { |
# does this user have privileges to post, etc? |
# does this user have privileges to post, etc? |
if ($env{'request.course.id'}) { |
if ($env{'request.course.id'} |
|
&& $cdom eq $env{'course.'.$env{'request.course.id'}.'.domain'} |
|
&& $cnum eq $env{'course.'.$env{'request.course.id'}.'.num'}) { |
$allowed=&Apache::lonnet::allowed('mdc',$env{'request.course.id'}); |
$allowed=&Apache::lonnet::allowed('mdc',$env{'request.course.id'}); |
$privileged=$allowed; |
$privileged=$allowed; |
if (($syllabus{'uploaded.lastmodified'}) && (!$forceedit)) { |
if (($syllabus{'uploaded.lastmodified'}) && (!$forceedit)) { |