'
+ my ($imgnum,$title, $show_number) = @_;
+ my $output = undef;
+ if (!$show_number) {
+ $output = '
'
.'
!['.&mt('Step [_1]',$imgnum).'](/res/adm/pages/bl_step'.$imgnum.'.gif)
'
- .$title
+ .' '.$title
.'
';
+ } else {
+ $output = '
'
+ .$title
+ .'
';
+ }
+
+ return $output;
}
##############################################
@@ -1969,7 +1968,7 @@ sub set_form_elements {
$values{$name}[$i] =~ s/([\r\n\f]+)/\\n/g;
$values{$name}[$i] =~ s/"/\\"/g;
}
- if ($$elements{$name} eq 'text') {
+ if (($$elements{$name} eq 'text') || ($$elements{$name} eq 'hidden')) {
my $numvalues = @{$values{$name}};
if ($numvalues > 1) {
my $valuestring = join('","',@{$values{$name}});
@@ -2004,6 +2003,8 @@ sub set_form_elements {
$output .= qq|
if (courseForm.elements['$name'].value == "$value") {
courseForm.elements['$name'].checked = true;
+ } else {
+ courseForm.elements['$name'].checked = false;
}|;
}
}
@@ -2045,6 +2046,7 @@ sub set_form_elements {
}
}
$output .= "
+ return;
}\n";
return $output;
}
@@ -2133,6 +2135,41 @@ sub inittags {
}
+# USAGE: scripttag(scriptcode, [start|end|both]);
+#
+# EXAMPLES:
+# - scripttag("alert('Hello World!')", 'both')
+# returns:
+#
+#
+# NOTES:
+# - works currently only for javascripts
+#
+# OUTPUT:
+# Scriptcode properly enclosed in