--- loncom/interface/lonfeedback.pm 2002/01/01 15:02:31 1.21 +++ loncom/interface/lonfeedback.pm 2002/01/16 15:38:38 1.23 @@ -1,7 +1,7 @@ # The LearningOnline Network # Feedback # -# $Id: lonfeedback.pm,v 1.21 2002/01/01 15:02:31 www Exp $ +# $Id: lonfeedback.pm,v 1.23 2002/01/16 15:38:38 www Exp $ # # Copyright Michigan State University Board of Trustees # @@ -40,7 +40,9 @@ # 7/25 Gerd Kortemeyer # 7/26 Guy Albertelli # 7/26,8/10,10/1,11/5,11/6,12/27,12/29 Gerd Kortemeyer - +# YEAR=2002 +# 1/1,1/16 Gerd Kortemeyer +# package Apache::lonfeedback; @@ -197,7 +199,9 @@ sub screen_header { } if ($ENV{'request.course.id'}) { - if (&Apache::lonnet::allowed('pch',$ENV{'request.course.id'})) { + if (&Apache::lonnet::allowed('pch', + $ENV{'request.course.id'}. + ($ENV{'request.course.sec'}?'/'.$ENV{'request.course.sec'}:''))) { $options.='
'. 'Contribution to course discussion of resource'; $options.='
'. @@ -284,8 +288,9 @@ sub send_msg { my $sendsomething=0; map { if ($_) { + my $declutter=&Apache::lonnet::declutter($feedurl); unless (&Apache::lonmsg::user_normal_msg(split(/\:/,$_), - 'Feedback '.$feedurl,$email,$citations) eq 'ok') { + 'Feedback ['.$declutter.']',$email,$citations) eq 'ok') { $status.='
Error sending message to '.$_.'
'; } else { $sendsomething++; @@ -310,7 +315,8 @@ sub send_msg { sub adddiscuss { my ($symb,$email,$anon)=@_; my $status=''; - if (&Apache::lonnet::allowed('pch',$ENV{'request.course.id'})) { + if (&Apache::lonnet::allowed('pch',$ENV{'request.course.id'}. + ($ENV{'request.course.sec'}?'/'.$ENV{'request.course.sec'}:''))) { my %contrib=('message' => $email, 'sendername' => $ENV{'user.name'},