version 1.96, 2009/09/07 18:31:50
|
version 1.97, 2009/09/20 22:04:57
|
Line 141 ENDSCRIPT
|
Line 141 ENDSCRIPT
|
} |
} |
my $start_page = |
my $start_page = |
&Apache::loncommon::start_page("Syllabus", $rss_link.$js, |
&Apache::loncommon::start_page("Syllabus", $rss_link.$js, |
{'function' => $forcestudent, |
{'function' => undef, |
'domain' => $cdom, |
'domain' => $cdom, |
'force_register' => |
'force_register' => |
$env{'form.register'},}); |
$env{'form.register'},}); |
Line 232 ENDSCRIPT
|
Line 232 ENDSCRIPT
|
#--------Functions |
#--------Functions |
if( ($allowed || $privileged) && $target ne 'tex') { |
if( ($allowed || $privileged) && $target ne 'tex') { |
my $functions=&Apache::lonhtmlcommon::start_funclist(); |
my $functions=&Apache::lonhtmlcommon::start_funclist(); |
|
|
if ($allowed) { |
if ($allowed) { |
$functions.=&Apache::lonhtmlcommon::add_item_funclist( |
#if you have the register flag, keep it |
|
if($env{'form.register'} == 1) { |
|
$functions.=&Apache::lonhtmlcommon::add_item_funclist( |
|
'<a href="'.$r->uri.'?forcestudent=1®ister=1">' |
|
.&mt('Show Public View').'</a>' |
|
.&Apache::loncommon::help_open_topic( |
|
'Uploaded_Templates_PublicView')); |
|
} else { |
|
$functions.=&Apache::lonhtmlcommon::add_item_funclist( |
'<a href="'.$r->uri.'?forcestudent=1">' |
'<a href="'.$r->uri.'?forcestudent=1">' |
.&mt('Show Public View').'</a>' |
.&mt('Show Public View').'</a>' |
.&Apache::loncommon::help_open_topic( |
.&Apache::loncommon::help_open_topic( |
'Uploaded_Templates_PublicView')); |
'Uploaded_Templates_PublicView')); |
|
} |
} elsif ($privileged) { |
} elsif ($privileged) { |
$functions.=&Apache::lonhtmlcommon::add_item_funclist( |
if($env{'form.register'} == 1) { |
|
$functions.=&Apache::lonhtmlcommon::add_item_funclist( |
|
'<a href="'.$r->uri.'?forceedit=1®ister=1">' |
|
.&mt('Edit').'</a>'); |
|
} else { |
|
$functions.=&Apache::lonhtmlcommon::add_item_funclist( |
'<a href="'.$r->uri.'?forceedit=1">' |
'<a href="'.$r->uri.'?forceedit=1">' |
.&mt('Edit').'</a>'); |
.&mt('Edit').'</a>'); |
|
} |
} |
} |
|
|
$functions.=&Apache::lonhtmlcommon::end_funclist(); |
$functions.=&Apache::lonhtmlcommon::end_funclist(); |