X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/mfinanz.git/blobdiff_plain/78f0df906055d13bbbb9f84e900a7c82a67d0045..61d89baf2eb6f0524c6b2eb561df2687e07ad6c8:/SL/Form.pm diff --git a/SL/Form.pm b/SL/Form.pm index 6ad6a9208..20acf122c 100644 --- a/SL/Form.pm +++ b/SL/Form.pm @@ -466,13 +466,13 @@ sub info { if (!$self->{header}) { $self->header; - print qq| -
|; + print qq||; } print qq| - -$msg +
+ + |; } else { @@ -1547,15 +1547,21 @@ sub datetonum { # Database routines used throughout +sub _dbconnect_options { + my $self = shift; + my $options = { pg_enable_utf8 => $::locale->is_utf8, + @_ }; + + return $options; +} + sub dbconnect { $main::lxdebug->enter_sub(2); my ($self, $myconfig) = @_; # connect to database - my $dbh = - DBI->connect($myconfig->{dbconnect}, - $myconfig->{dbuser}, $myconfig->{dbpasswd}) + my $dbh = DBI->connect($myconfig->{dbconnect}, $myconfig->{dbuser}, $myconfig->{dbpasswd}, $self->_dbconnect_options) or $self->dberror; # set db options @@ -1574,9 +1580,7 @@ sub dbconnect_noauto { my ($self, $myconfig) = @_; # connect to database - my $dbh = - DBI->connect($myconfig->{dbconnect}, $myconfig->{dbuser}, - $myconfig->{dbpasswd}, { AutoCommit => 0 }) + my $dbh = DBI->connect($myconfig->{dbconnect}, $myconfig->{dbuser}, $myconfig->{dbpasswd}, $self->_dbconnect_options(AutoCommit => 0)) or $self->dberror; # set db options