projects
/
kivitendo-erp.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
927ead5
)
JavaScript-String-Escaping
author
Moritz Bunkus
<m.bunkus@linet-services.de>
Mon, 27 Dec 2010 12:52:28 +0000
(13:52 +0100)
committer
Moritz Bunkus
<m.bunkus@linet-services.de>
Mon, 27 Dec 2010 12:52:28 +0000
(13:52 +0100)
SL/Template/Plugin/L.pm
patch
|
blob
|
history
diff --git
a/SL/Template/Plugin/L.pm
b/SL/Template/Plugin/L.pm
index
f776af8
..
844c88d
100644
(file)
--- a/
SL/Template/Plugin/L.pm
+++ b/
SL/Template/Plugin/L.pm
@@
-21,6
+21,12
@@
sub _H {
return $::locale->quote_special_chars('HTML', $string);
}
+sub _J {
+ my $string = "" . shift;
+ $string =~ s/\"/\\\"/g;
+ return $string;
+}
+
sub _hashify {
return (@_ && (ref($_[0]) eq 'HASH')) ? %{ $_[0] } : @_;
}