note 60535 deleted from function.serialize by aharvey
| From: | aharvey@php.net | Date: | Tue, 06 Nov 2012 02:09:55 +0000 |
| Subject: | note 60535 deleted from function.serialize by aharvey | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-191765@lists.php.net to get a copy of this message | ||
Note Submitter: varrah NO_GARBAGE_OR_SPAM AT mail DOT ru
----
andrea at 3site dot it gave a link for a JavaScript serialization class, but be prepared! This class
works only on single-byte symbols, since JS str.length property gives the length of the string in
SYMBOLS, not bytes (as PHP serialize() does), so a Unicode string JS-serialized in a way like:
strSerialized = "s:" + strOriginal.length + ":" + strOriginal;
will not be unserialized correctly by PHP.