--- loncom/interface/lonfeedback.pm 2003/03/29 22:50:22 1.42 +++ loncom/interface/lonfeedback.pm 2003/07/01 19:27:31 1.48 @@ -1,7 +1,7 @@ # The LearningOnline Network # Feedback # -# $Id: lonfeedback.pm,v 1.42 2003/03/29 22:50:22 www Exp $ +# $Id: lonfeedback.pm,v 1.48 2003/07/01 19:27:31 albertel Exp $ # # Copyright Michigan State University Board of Trustees # @@ -56,6 +56,7 @@ sub mail_screen { my ($r,$feedurl,$options) = @_; my $bodytag=&Apache::loncommon::bodytag('Resource Feedback and Discussion', '','onLoad="window.focus();"'); + my $latexHelp = Apache::loncommon::helpLatexCheatsheet(); $r->print(< @@ -105,11 +106,13 @@ sub mail_screen { $bodytag

$feedurl

-
+ Please check at least one of the following feedback types: $options
My question/comment/feedback:

+$latexHelp

Attachment (128 KB max size): @@ -218,7 +221,7 @@ sub screen_header { sub resource_output { my ($feedurl) = @_; - my $usersaw=&Apache::lonnet::ssi($feedurl); + my $usersaw=&Apache::lonnet::ssi_body($feedurl); $usersaw=~s/\]*\>//gi; $usersaw=~s/\<\/body\>//gi; $usersaw=~s/\//gi; @@ -240,9 +243,9 @@ sub clear_out_html { BR=>1, TT=>1, STRONG=>1, BLOCKQUOTE=>1, DIV=>1, IMG=>1); $message =~ s/\<(\/?\s*(\w+)[^\>\<]*)/ - {($html{uc($2)}&(length($1)<1000))?"\<$1":"\<$1"}/ge; + {($html{uc($2)}&&(length($1)<1000))?"\<$1":"\<$1"}/ge; $message =~ s/(\]*)\>/ - {($html{uc($2)}&(length($1)<1000))?"$1\>":"$1\>"}/ge; + {($html{uc($2)}&&(length($1)<1000))?"$1\>":"$1\>"}/ge; } else { $message=~s/\<\/*m\s*\>//g; $message=~s/\Error sending message to '.$_.'
'; } else { $sendsomething++; @@ -382,7 +386,7 @@ sub adddiscuss { $ENV{'environment.middlename'}.' '. $ENV{'environment.lastname'}.' '. $ENV{'enrironment.generation'}, - 'attachment' => $attachmenturl); + 'attachmenturl'=> $attachmenturl); if ($anon) { $contrib{'anonymous'}='true'; } @@ -565,7 +569,7 @@ sub handler { my $attachmenturl=''; if ($ENV{'form.attachment.filename'}) { unless (length($ENV{'form.attachment'})>131072) { - $attachmenturl=&Apache::lonnet::userfileupload('attachment',1); + $attachmenturl=&Apache::lonnet::userfileupload('attachment'); } } # Filter HTML out of message (could be nasty) @@ -579,7 +583,8 @@ sub handler { my ($typestyle,%to) = &decide_receiver($feedurl); # Actually send mail - my ($status,$numsent)=&send_msg($feedurl,$email,$citations,%to); + my ($status,$numsent)=&send_msg($feedurl,$email,$citations, + $attachmenturl,%to); # Discussion? Store that.