From 43ec195c6ec636ff221953116917ecd687fee5fb Mon Sep 17 00:00:00 2001 From: Lars Kneschke Date: Thu, 9 Oct 2003 23:38:24 +0000 Subject: [PATCH] added check if function iconv exists --- phpgwapi/inc/class.translation_sql.inc.php | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/phpgwapi/inc/class.translation_sql.inc.php b/phpgwapi/inc/class.translation_sql.inc.php index 0fbb3ef5b0..53c4ec7476 100644 --- a/phpgwapi/inc/class.translation_sql.inc.php +++ b/phpgwapi/inc/class.translation_sql.inc.php @@ -272,11 +272,17 @@ { return mb_convert_encoding($data,$to,$from); } - if (($data = iconv($from,$to,$date))) + if(function_exists('iconv')) { - return $data; + if (($data = iconv($from,$to,$date))) + { + return $data; + } } - die("

Can't convert from charset '$from' to '$to' without the mbstring extension !!!

"); + #die("

Can't convert from charset '$from' to '$to' without the mbstring extension !!!

"); + + // this is not good, not convert did succed + return $data; } /*!