From d3c781836fb4e3baa0b5c9d8dbfd438f48876d50 Mon Sep 17 00:00:00 2001 From: Kevin Fourie Date: Thu, 31 May 2007 16:14:12 +0000 Subject: [PATCH] KTS-1859 "non-ASCII chars sometimes display wrong in Browse" Fixed. --- plugins/ktcore/KTColumns.inc.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/plugins/ktcore/KTColumns.inc.php b/plugins/ktcore/KTColumns.inc.php index e789e4c..d4e3324 100644 --- a/plugins/ktcore/KTColumns.inc.php +++ b/plugins/ktcore/KTColumns.inc.php @@ -82,9 +82,9 @@ class AdvancedTitleColumn extends AdvancedColumn { function renderDocumentLink($aDataRow) { /* this chack has to be done so that any titles longer than 40 characters is not displayed incorrectly. as mozilla cannot wrap text without white spaces */ - if(strlen($aDataRow["document"]->getName()) > 40){ + if (mb_strlen($aDataRow["document"]->getName(), 'UTF-8') > 40) { mb_internal_encoding("UTF-8"); - $outStr = htmlentities(mb_substr($aDataRow["document"]->getName(), 0, 40)."...", ENT_NOQUOTES, 'UTF-8'); + $outStr = htmlentities(mb_substr($aDataRow["document"]->getName(), 0, 40, 'UTF-8')."...", ENT_NOQUOTES, 'UTF-8'); }else{ $outStr = htmlentities($aDataRow["document"]->getName(), ENT_NOQUOTES, 'UTF-8'); } -- libgit2 0.21.4