X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;f=SL%2FTemplate.pm;h=e4e940ba2d2370b005cb03321f58d89eeb3e757a;hb=6b293028a4c1f27bcb07c665a4f43f5362debf1f;hp=9e25f39ee0c43baaaa735cdee4732e9c410d8170;hpb=6534db924d0c874b31306d827ffb011f66a6e591;p=kivitendo-erp.git diff --git a/SL/Template.pm b/SL/Template.pm index 9e25f39ee..e4e940ba2 100644 --- a/SL/Template.pm +++ b/SL/Template.pm @@ -91,7 +91,7 @@ sub format_string { '', '&', quotemeta("\n"), '"', '\$', '%', '_', '#', quotemeta('^'), - '{', '}', '<', '>', '£', "\r" + '{', '}', '<', '>', '£', "\r", '±', '\xe1', ], quotemeta("\\") => '\\textbackslash ', '' => '', @@ -107,6 +107,8 @@ sub format_string { '>' => '$>$', '£' => '\pounds ', "\r" => "", + '±' => '$\pm$', + '\xe1' => '$\bullet$', quotemeta('^') => '\^\\', quotemeta("\n") => '\newline ' ); @@ -124,6 +126,8 @@ sub format_string { $variable =~ s/\$\<\$${key}\$\>\$(.*?)\$<\$\/${key}\$>\$/\\${new}\{$1\}/gi; } + $variable =~ s/[\x00-\x1f]//g; + return $variable; } @@ -1307,16 +1311,17 @@ sub format_string { sub get_mime_type() { my ($self) = @_; - if ($self->{"form"}->{"format"} =~ /xml/i) { + if ($self->{"form"}->{"format"} =~ /elsterwinston/i) { return "application/xml "; + } elsif ($self->{"form"}->{"format"} =~ /elstertaxbird/i) { + return "application/x-taxbird"; } else { - return "text/xml"; + return "text"; } } sub uses_temp_file { -# my ($self) = @_; - # no tempfile needet for XML Output + # tempfile needet for XML Output return 1; }