#use CGI::Carp qw(fatalsToBrowser);
use CGI::Cookie;
- use List::Util qw( max min );
+ use List::Util qw( max min sum );
use Data::Dumper;
use Date::Format;
use Time::Local;
Lingua::EN::Inflect::classical names=>0; #Categorys
use Tie::IxHash;
use URI;
- use URI::Escape;
+ use URI::Escape 3.31;
use HTML::Entities;
use HTML::TreeBuilder;
use HTML::TableExtract qw(tree);
use Text::CSV_XS;
use Spreadsheet::WriteExcel;
use Spreadsheet::WriteExcel::Utility;
+ use Excel::Writer::XLSX;
+ use Excel::Writer::XLSX::Utility;
+
use Business::CreditCard 0.30; #for mask-aware cardtype()
use NetAddr::IP;
use Net::Ping;
use FS::UID qw( getotaker dbh datasrc driver_name );
use FS::Record qw( qsearch qsearchs fields dbdef
str2time_sql str2time_sql_closing
+ midnight_sql
);
use FS::Conf;
use FS::CGI qw(header menubar table itable ntable idiot
${$_[0]} =~ s/(['\\])/\\$1/g;
${$_[0]} =~ s/\r/\\r/g;
${$_[0]} =~ s/\n/\\n/g;
+ # prevent premature termination of the script
+ ${$_[0]} =~ s[</script>][<\\/script>]ig;
${$_[0]} = "'". ${$_[0]}. "'";
};
[ 'freeside' => '%%%FREESIDE_DOCUMENT_ROOT%%%' ],
],
escape_flags => { 'h' => \&RT::Interface::Web::EscapeUTF8,
+ 'u' => \&RT::Interface::Web::EscapeURI,
+ 'j' => \&RT::Interface::Web::EscapeJS,
'js_string' => $js_string_sub,
},
compiler => HTML::Mason::Compiler::ToObject->new(