ソースを参照

Better handling of unexpected/invalid characters in an UTF-8 file.

git-svn-id: http://svn.code.sf.net/p/itop/code/trunk@880 a333f486-631f-4898-b8df-5754b55c2be0
dflaven 14 年 前
コミット
9f36e2fb07
1 ファイル変更1 行追加1 行削除
  1. 1 1
      pages/csvimport.php

+ 1 - 1
pages/csvimport.php

@@ -835,7 +835,7 @@ EOF
 		// Compute a subset of the data set, now that we know the charset
 		if ($sEncoding == 'UTF-8')
 		{
-			$sUTF8Data = $sCSVData;		
+			$sUTF8Data = iconv('UTF-8', 'UTF-8//IGNORE//TRANSLIT', $sCSVData);
 		}
 		else
 		{