| 1 | ################################################################################ |
1 | ################################################################################ |
| 2 | # WeBWorK Online Homework Delivery System |
2 | # WeBWorK Online Homework Delivery System |
| 3 | # Copyright © 2000-2003 The WeBWorK Project, http://openwebwork.sf.net/ |
3 | # Copyright © 2000-2003 The WeBWorK Project, http://openwebwork.sf.net/ |
| 4 | # $CVSHeader: webwork-modperl/lib/WeBWorK/ContentGenerator/Instructor/SendMail.pm,v 1.25 2004/05/05 01:53:51 gage Exp $ |
4 | # $CVSHeader: webwork-modperl/lib/WeBWorK/ContentGenerator/Instructor/SendMail.pm,v 1.26 2004/05/07 18:49:40 sh002i Exp $ |
| 5 | # |
5 | # |
| 6 | # This program is free software; you can redistribute it and/or modify it under |
6 | # This program is free software; you can redistribute it and/or modify it under |
| 7 | # the terms of either: (a) the GNU General Public License as published by the |
7 | # the terms of either: (a) the GNU General Public License as published by the |
| 8 | # Free Software Foundation; either version 2, or (at your option) any later |
8 | # Free Software Foundation; either version 2, or (at your option) any later |
| 9 | # version, or (b) the "Artistic License" which comes with this package. |
9 | # version, or (b) the "Artistic License" which comes with this package. |
| … | |
… | |
| 746 | $msg =~ s/(\$SECTION)/eval($1)/ge; |
746 | $msg =~ s/(\$SECTION)/eval($1)/ge; |
| 747 | $msg =~ s/(\$RECITATION)/eval($1)/ge; |
747 | $msg =~ s/(\$RECITATION)/eval($1)/ge; |
| 748 | $msg =~ s/(\$EMAIL)/eval($1)/ge; |
748 | $msg =~ s/(\$EMAIL)/eval($1)/ge; |
| 749 | $msg =~ s/(\$LOGIN)/eval($1)/ge; |
749 | $msg =~ s/(\$LOGIN)/eval($1)/ge; |
| 750 | $msg =~ s/\$COL\[ *-/\$COL\[$endCol-/g; |
750 | $msg =~ s/\$COL\[ *-/\$COL\[$endCol-/g; |
| 751 | $msg =~ s/(\$COL\[.*?\])/eval($1)/ge; |
751 | $msg =~ s/(\$COL\[.*?\])/eval($1)/ge if defined($COL[0]); # prevents extraneous error messages. |
|
|
752 | |
| 752 | |
753 | |
| 753 | $msg =~ s/\r//g; |
754 | $msg =~ s/\r//g; |
| 754 | |
755 | |
| 755 | my $preview_header = CGI::pre("",data_format(0..($#COL)),"<br>", data_format2(@COL)). |
756 | my $preview_header = CGI::pre("",data_format(0..($#COL)),"<br>", data_format2(@COL)). |
| 756 | CGI::h3( "This sample mail would be sent to $EMAIL"); |
757 | CGI::h3( "This sample mail would be sent to $EMAIL"); |