version 1.61, 2010/12/02 23:05:42
|
version 1.66, 2011/03/03 17:29:29
|
Line 244 function initialize_codes() {
|
Line 244 function initialize_codes() {
|
} |
} |
|
|
my $js = '<script type="text/javascript">'."\n$scripttag\n$jscript\n". |
my $js = '<script type="text/javascript">'."\n$scripttag\n$jscript\n". |
'</script>'; |
$loaditems.'</script>'; |
my %add_entries = (topmargin => "0", |
my %add_entries = (topmargin => "0", |
marginheight => "0", |
marginheight => "0", |
onLoad =>"initialize_codes()",); |
onLoad =>"initialize_codes()",); |
Line 532 sub print_request_receipt {
|
Line 532 sub print_request_receipt {
|
my $totcodes = 0; |
my $totcodes = 0; |
my %coursecodes; |
my %coursecodes; |
$totcodes = &Apache::courseclassifier::retrieve_instcodes(\%coursecodes,$defdom,$totcodes); |
$totcodes = &Apache::courseclassifier::retrieve_instcodes(\%coursecodes,$defdom,$totcodes); |
my $coursecode; |
|
my @standardnames = &Apache::loncommon::get_standard_codeitems(); |
my @standardnames = &Apache::loncommon::get_standard_codeitems(); |
if ($totcodes > 0) { |
if ($totcodes > 0) { |
$coursecode = &Apache::courseclassifier::instcode_from_selectors($defdom); |
my $noregexps = 1; |
|
$coursecode = |
|
&Apache::courseclassifier::instcode_from_selectors($defdom,$noregexps); |
} |
} |
if ($coursecode eq '') { |
if ($coursecode eq '') { |
foreach my $item (@standardnames) { |
foreach my $item (@standardnames) { |
Line 557 sub print_request_receipt {
|
Line 558 sub print_request_receipt {
|
sourceurl => 'URL', |
sourceurl => 'URL', |
date => 'Date/Time', |
date => 'Date/Time', |
secn => 'Section', |
secn => 'Section', |
asup => 'A support request has been sent to', |
|
warn => 'Warning: Problem with support e-mail address', |
warn => 'Warning: Problem with support e-mail address', |
your => 'Your support request contained the following information', |
your => 'Your support request contained the following information', |
sect => 'section', |
sect => 'section', |
Line 688 END
|
Line 688 END
|
$bad_email = 1; |
$bad_email = 1; |
} |
} |
} |
} |
if ($bad_email) { |
|
$r->print(' |
my $message; |
<h3>'.$lt{'warn'}.'</h3>'. |
if (!$bad_email) { |
&mt('As the e-mail address provided for this LON-CAPA server ([_1]) does not appear to be a valid e-mail address, your support request has <b>not</b> been sent to the LON-CAPA support staff or administrator at your institution.',$to).' '.&mt('Instead a copy has been sent to the LON-CAPA support team at Michigan State University.')); |
$message = &Apache::lonhtmlcommon::confirm_success( |
$to = 'helpdesk@lon-capa.org'; |
&mt('A support request has been sent to [_1]','<tt>'.$to.'</tt>')); |
} else { |
} else { |
$r->print('<h3>'.$lt{'asup'}.' '.$to.'</h3>'); |
$message = &Apache::lonhtmlcommon::confirm_success( |
|
$lt{'warn'}.'<br />' |
|
.&mt('As the e-mail address provided for this LON-CAPA server ([_1]) does not appear to be a valid e-mail address, your support request has [_2]not[_3] been sent to the LON-CAPA support staff or administrator at your institution.','<tt>'.$to.'</tt>','<b>','</b>') |
|
.' '.&mt('Instead a copy has been sent to the LON-CAPA support team at Michigan State University.'),1); |
|
$to = 'helpdesk@lon-capa.org'; |
} |
} |
|
$r->print(&Apache::loncommon::confirmwrapper($message)); |
|
|
if (defined($env{'form.email'})) { |
if (defined($env{'form.email'})) { |
$env{'form.email'} =~ s/^\s+//; |
$env{'form.email'} =~ s/^\s+//; |
$env{'form.email'} =~ s/\s+$//; |
$env{'form.email'} =~ s/\s+$//; |
Line 743 END
|
Line 749 END
|
$fname = $1; |
$fname = $1; |
$displaymsg .= '<br />' |
$displaymsg .= '<br />' |
.&mt('An uploaded screenshot file [_1] ([_2] bytes) was included in the request sent by [_3].' |
.&mt('An uploaded screenshot file [_1] ([_2] bytes) was included in the request sent by [_3].' |
,'<span class="LC_filename">'.$fname.'<span>' |
,'<span class="LC_filename">'.$fname.'</span>' |
,$attachmentsize |
,$attachmentsize |
,$env{'user.name'}.':'.$env{'user.domain'} |
,$env{'user.name'}.':'.$env{'user.domain'} |
); |
); |
Line 773 END
|
Line 779 END
|
if ($bcc ne '') { |
if ($bcc ne '') { |
$msg->add("Bcc" => $bcc); |
$msg->add("Bcc" => $bcc); |
} |
} |
$msg->add('Content-type','text/plain; charset=UTF-8'); |
$msg->attr("content-type" => "text/plain"); |
|
$msg->attr("content-type.charset" => "UTF-8"); |
|
|
if ($attachmentpath) { |
if ($attachmentpath) { |
my ($type, $encoding) = MIME::Types::by_suffix($attachmentpath); |
my ($type, $encoding) = MIME::Types::by_suffix($attachmentpath); |