note 97177 added to function.unpack
| From: | norwood at computer dot org | Date: | Tue, 06 Apr 2010 21:15:53 +0000 |
| Subject: | note 97177 added to function.unpack | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-167740@lists.php.net to get a copy of this message | ||
Reading a text cell from an Excel spreadsheet returned a string with low-order embedded nulls:
0x4100 0x4200 etc. To remove the nulls, used
$strWithoutNulls = implode( '', explode( "\0", $strWithNulls ) );
(unpack() didn't seem to help much here; needed chars back to re-constitute the string, not
integers.)
----
Server IP: 64.71.164.2
Probable Submitter: 76.108.146.223
----
Manual Page -- http://www.php.net/manual/en/function.unpack.php
Edit -- https://master.php.net/note/edit/97177
Del: integrated -- https://master.php.net/note/delete/97177/integrated
Del: useless -- https://master.php.net/note/delete/97177/useless
Del: bad code -- https://master.php.net/note/delete/97177/bad+code
Del: spam -- https://master.php.net/note/delete/97177/spam
Del: non-english -- https://master.php.net/note/delete/97177/non-english
Del: in docs -- https://master.php.net/note/delete/97177/in+docs
Del: other reasons-- https://master.php.net/note/delete/97177
Reject -- https://master.php.net/note/reject/97177
Search -- https://master.php.net/manage/user-notes.php