note 116763 added to function.str-getcsv

From: Date: Tue, 24 Feb 2015 14:53:20 +0000
Subject: note 116763 added to function.str-getcsv
Groups: php.notes 
Request: Send a blank email to php-notes+get-201800@lists.php.net to get a copy of this message
PHP is failing when parsing UTF-8 with Byte Order Mark. Strip it with this one from string before passing it to csv parser: <?php $bom = pack('CCC', 0xEF, 0xBB, 0xBF); if (strncmp($yourString, $bom, 3) === 0) { $body = substr($yourString, 3); } ?> ---- Server IP: 72.52.91.14 Probable Submitter: 82.135.112.130 ---- Manual Page -- http://php.net/manual/en/function.str-getcsv.php Edit -- https://master.php.net/note/edit/116763 Del: integrated -- https://master.php.net/note/delete/116763/integrated Del: useless -- https://master.php.net/note/delete/116763/useless Del: bad code -- https://master.php.net/note/delete/116763/bad+code Del: spam -- https://master.php.net/note/delete/116763/spam Del: non-english -- https://master.php.net/note/delete/116763/non-english Del: in docs -- https://master.php.net/note/delete/116763/in+docs Del: other reasons-- https://master.php.net/note/delete/116763 Reject -- https://master.php.net/note/reject/116763 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#201800) next »