version 1.78, 2003/06/19 03:03:32
|
version 1.86, 2003/08/28 16:43:12
|
Line 178 sub registerurl {
|
Line 178 sub registerurl {
|
if (($ENV{'browser.interface'} eq 'textual') || |
if (($ENV{'browser.interface'} eq 'textual') || |
($ENV{'environment.remote'} eq 'off') || |
($ENV{'environment.remote'} eq 'off') || |
((($ENV{'request.publicaccess'}) || |
((($ENV{'request.publicaccess'}) || |
(!&Apache::lonnet::is_on_map($ENV{'REQUEST_URI'}))) && |
(!&Apache::lonnet::is_on_map( |
|
&Apache::lonnet::unescape($ENV{'REQUEST_URI'})))) && |
(!$forcereg))) { |
(!$forcereg))) { |
return $result. |
return $result. |
'<script type="text/javascript">function LONCAPAreg(){;} function LONCAPAstale(){}</script>'.$force_title; |
'<script type="text/javascript">function LONCAPAreg(){;} function LONCAPAstale(){}</script>'.$force_title; |
Line 229 sub innerregister {
|
Line 230 sub innerregister {
|
} |
} |
if (&Apache::lonmsg::newmail()) { |
if (&Apache::lonmsg::newmail()) { |
$newmail=($textual? |
$newmail=($textual? |
'<b><a href="/adm/communicate">You have new messages</a></b><br />': |
'<b><a href="/adm/communicate" target="_top">You have new messages</a></b><br />': |
'swmenu.setstatus("you have","messages");'); |
'swmenu.setstatus("you have","messages");'); |
} |
} |
if ($noremote) { |
if ($noremote) { |
Line 245 sub innerregister {
|
Line 246 sub innerregister {
|
my $hwkadd=''; |
my $hwkadd=''; |
if |
if |
($ENV{'request.filename'}=~/\.(problem|exam|quiz|assess|survey|form)$/) { |
($ENV{'request.filename'}=~/\.(problem|exam|quiz|assess|survey|form)$/) { |
if (&Apache::lonnet::allowed('vgr',$ENV{'request.course.id'})) { |
my $crs='/'.$ENV{'request.course.id'}; |
|
if ($ENV{'request.course.sec'}) { |
|
$crs.='_'.$ENV{'request.course.sec'}; |
|
} |
|
$crs=~s/\_/\//g; |
|
|
|
if (&Apache::lonnet::allowed('vgr',$crs)) { |
$hwkadd.=&switch('','',7,1,'subm.gif','view sub-','missions', |
$hwkadd.=&switch('','',7,1,'subm.gif','view sub-','missions', |
"gocmd('/adm/grades','submission')", |
"gocmd('/adm/grades','submission')", |
'View user submissions for this assessment resource'); |
'View user submissions for this assessment resource'); |
} |
} |
if (&Apache::lonnet::allowed('mgr',$ENV{'request.course.id'})) { |
if (&Apache::lonnet::allowed('mgr',$crs)) { |
$hwkadd.=&switch('','',7,2,'pgrd.gif','problem','grades', |
$hwkadd.=&switch('','',7,2,'pgrd.gif','problem','grades', |
"gocmd('/adm/grades','gradingmenu')", |
"gocmd('/adm/grades','gradingmenu')", |
'Modify user grades for this assessment resource'); |
'Modify user grades for this assessment resource'); |
} |
} |
if (&Apache::lonnet::allowed('opa',$ENV{'request.course.id'})) { |
if (&Apache::lonnet::allowed('opa',$crs)) { |
$hwkadd.=&switch('','',7,3,'pparm.gif','problem','parms', |
$hwkadd.=&switch('','',7,3,'pparm.gif','problem','parms', |
"gocmd('/adm/parmset','set')", |
"gocmd('/adm/parmset','set')", |
'Modify deadlines, etc, for this assessment resource'); |
'Modify deadlines, etc, for this assessment resource'); |
Line 328 c&8&1
|
Line 335 c&8&1
|
c&8&2 |
c&8&2 |
s&8&3&prt.gif&prepare&printout&gopost('/adm/printout',currentURL)&Prepare a printable document |
s&8&3&prt.gif&prepare&printout&gopost('/adm/printout',currentURL)&Prepare a printable document |
s&9&1&sbkm.gif&set&bookmark&set_bookmark()&Set a bookmark for this resource&2 |
s&9&1&sbkm.gif&set&bookmark&set_bookmark()&Set a bookmark for this resource&2 |
s&9&2&vbkm.gif&view&bookmark&edit_bookmarks()&Use or edit my bookmark collection&2 |
|
s&9&3&anot.gif&anno-&tations&annotate()&Make notes and annotations about this resource&2 |
s&9&3&anot.gif&anno-&tations&annotate()&Make notes and annotations about this resource&2 |
ENDMENUITEMS |
ENDMENUITEMS |
unless ($ENV{'REQUEST_URI'}=~/\/(bulletinboard|smppg|navmaps|syllabus|aboutme)(\?|$)/) { |
unless ($ENV{'REQUEST_URI'}=~/\/(bulletinboard|smppg|navmaps|syllabus|aboutme)(\?|$)/) { |
$menuitems.=(<<ENDREALRES); |
$menuitems.=(<<ENDREALRES); |
s&6&3&catalog.gif&catalog&info&catalog_info()&Show catalog information |
s&6&3&catalog.gif&catalog&info&catalog_info()&Show catalog information |
s&8&1&eval.gif&evaluate&this&gopost('/adm/evaluate',currentURL)&Provide my evaluation of this resource |
s&8&1&eval.gif&evaluate&this&gopost('/adm/evaluate',currentURL,1)&Provide my evaluation of this resource |
s&8&2&fdbk.gif&feedback&discuss&gopost('/adm/feedback',currentURL)&Provide feedback messages or contribute to the course discussion about this resource |
s&8&2&fdbk.gif&feedback&discuss&gopost('/adm/feedback',currentURL,1)&Provide feedback messages or contribute to the course discussion about this resource |
ENDREALRES |
ENDREALRES |
} |
} |
my $buttons=''; |
my $buttons=''; |
Line 371 $form
|
Line 377 $form
|
ENDREGTEXT |
ENDREGTEXT |
# Registered, graphical output |
# Registered, graphical output |
} else { |
} else { |
|
my $requri=(split(/\?/,$ENV{'REQUEST_URI'}))[0]; |
|
$requri=&Apache::lonnet::unescape($requri); |
$result = (<<ENDREGTHIS); |
$result = (<<ENDREGTHIS); |
|
|
<script language="JavaScript"> |
<script language="JavaScript"> |
Line 383 var swmenu=null;
|
Line 391 var swmenu=null;
|
$timesync |
$timesync |
$newmail |
$newmail |
$buttons |
$buttons |
swmenu.currentURL=window.location.pathname; |
swmenu.currentURL="$requri"; |
swmenu.reloadURL=window.location.pathname+window.location.search; |
swmenu.reloadURL=swmenu.currentURL+window.location.search; |
swmenu.currentSymb="$ENV{'request.symb'}"; |
swmenu.currentSymb="$ENV{'request.symb'}"; |
swmenu.reloadSymb="$ENV{'request.symb'}"; |
swmenu.reloadSymb="$ENV{'request.symb'}"; |
swmenu.currentStale=0; |
swmenu.currentStale=0; |
Line 708 sub rawconfig {
|
Line 716 sub rawconfig {
|
$output.=&secondlevel( |
$output.=&secondlevel( |
$uname,$udom,$rol,$crs,$pub,$con,$row,$col,$prt,$img,$top,$bot,$act,$desc); |
$uname,$udom,$rol,$crs,$pub,$con,$row,$col,$prt,$img,$top,$bot,$act,$desc); |
} |
} |
} elsif (($pro=~/p(\w+)/) && ($prt)) { |
} elsif (($pro=~/^p(\w+)/) && ($prt)) { |
if (&Apache::lonnet::allowed($1,$prt)) { |
if (&Apache::lonnet::allowed($1,$prt)) { |
$output.=switch($uname,$udom,$row,$col,$img,$top,$bot,$act,$desc); |
$output.=switch($uname,$udom,$row,$col,$img,$top,$bot,$act,$desc); |
} |
} |
Line 716 sub rawconfig {
|
Line 724 sub rawconfig {
|
if ($ENV{'request.course.fn'}) { |
if ($ENV{'request.course.fn'}) { |
$output.=switch($uname,$udom,$row,$col,$img,$top,$bot,$act,$desc); |
$output.=switch($uname,$udom,$row,$col,$img,$top,$bot,$act,$desc); |
} |
} |
|
} elsif ($pro =~ /^course_(.*)$/) { |
|
# Check for permissions inside of a course |
|
if (($ENV{'request.course.id'}) && |
|
(&Apache::lonnet::allowed($1,$ENV{'request.course.id'}. |
|
($ENV{'request.course.sec'}?'/'.$ENV{'request.course.sec'}:'')) |
|
)) { |
|
$output.=switch($uname,$udom,$row,$col,$img,$top,$bot,$act,$desc); |
|
} |
} elsif ($pro eq 'author') { |
} elsif ($pro eq 'author') { |
if ($author) { |
if ($author) { |
if ((($prt eq 'rca') && ($ENV{'request.role'}=~/^ca/)) || |
if ((($prt eq 'rca') && ($ENV{'request.role'}=~/^ca/)) || |