version 1.51, 2013/09/22 15:56:24
|
version 1.52, 2025/01/28 19:49:20
|
Line 86 sub print_aboutme_content_template {
|
Line 86 sub print_aboutme_content_template {
|
&print_template($r,$syllabusfields{$field},$message,$allowed,'LC_Box'); |
&print_template($r,$syllabusfields{$field},$message,$allowed,'LC_Box'); |
} |
} |
if($allowed) { |
if($allowed) { |
&print_editbox_template($r,$syllabus{$field},$field); |
&print_editbox_template($r,$syllabus{$field},$field,$syllabusfields{$field}); |
} |
} |
|
|
} else { |
} else { |
Line 130 sub print_end_template {
|
Line 130 sub print_end_template {
|
} |
} |
|
|
sub print_editbox_template { |
sub print_editbox_template { |
my ($r,$content,$field) = @_; |
my ($r,$content,$field,$fieldname) = @_; |
$r->print('<textarea cols="81" rows="6" name="'.$field.'">'. |
my $labeltext = &HTML::Entities::encode(&mt('Edit [_1]',$fieldname),'"&<>'); |
|
$r->print('<textarea cols="81" rows="6" name="'.$field.'" aria-label="'.$labeltext.'">'. |
&HTML::Entities::encode($content,'"&<>'). |
&HTML::Entities::encode($content,'"&<>'). |
'</textarea><br />'."\n"); |
'</textarea><br />'."\n"); |
&print_saveall_template($r); |
&print_saveall_template($r); |
} |
} |
|
|
sub print_textarea_template { |
sub print_textarea_template { |
my ($r, $content, $field, $wysiwyg) = @_; |
my ($r, $content, $field, $fieldname, $wysiwyg) = @_; |
$r->print('<textarea cols="81" rows="6" class="'.$wysiwyg.'" id="'.$field.'" name="'.$field.'">'. |
my $labeltext = &HTML::Entities::encode(&mt('Edit [_1]',$fieldname),'"&<>'); |
|
$r->print('<textarea cols="81" rows="6" class="'.$wysiwyg.'" id="'.$field.'" name="'.$field.'" aria-label="'.$labeltext.'">'. |
&HTML::Entities::encode($content, '"&<>'). |
&HTML::Entities::encode($content, '"&<>'). |
'</textarea><br />'); |
'</textarea><br />'); |
} |
} |
Line 183 sub print_template_fields {
|
Line 185 sub print_template_fields {
|
$r->print($message); |
$r->print($message); |
if ($allowed) { |
if ($allowed) { |
$r->print("<br /><div>"); |
$r->print("<br /><div>"); |
&Apache::lontemplate::print_textarea_template($r, $data{$field}, |
&print_textarea_template($r, $data{$field}, |
$field, $default_rich_text); |
$field, $fields{$field}, $default_rich_text); |
&print_saveall_template($r); |
&print_saveall_template($r); |
$r->print("</div>"); |
$r->print("</div>"); |
} |
} |