From 165227635bb5d6676ff59b2098711ee80767a03f Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sat, 14 May 2005 14:57:52 +0000 Subject: [PATCH] =?UTF-8?q?Fix:=20Fonction=20dolibarr=5Ftrunc=20=E9tait=20?= =?UTF-8?q?ineffecive?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- htdocs/lib/functions.inc.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/lib/functions.inc.php b/htdocs/lib/functions.inc.php index ca3d325c928..b4d1f46b170 100644 --- a/htdocs/lib/functions.inc.php +++ b/htdocs/lib/functions.inc.php @@ -368,7 +368,7 @@ function dolibarr_print_phone($phone,$country="FR") */ function dolibarr_trunc($string,$size=40) { - if (sizeof($string) > $size) return substr($string,0,$size).'...'; + if (strlen($string) > $size) return substr($string,0,$size).'...'; else return $string; }