note 90113 added to function.unserialize

From: Date: Tue, 07 Apr 2009 09:07:42 +0000
Subject: note 90113 added to function.unserialize
Groups: php.notes 
Request: Send a blank email to php-notes+get-152882@lists.php.net to get a copy of this message
When dealing with a string which contain "\r", it seems that the length is not evaluated correctly. The following solves the problem for me : // remove the \r caracters from the $unserialized string $unserialized = str_replace("\r","",$unserialized); // and then unserialize() unserialize($unserialized); ---- Server IP: 69.147.83.197 Probable Submitter: 83.114.184.24 ---- Manual Page -- http://www.php.net/manual/en/function.unserialize.php Edit -- https://master.php.net/note/edit/90113 Del: integrated -- https://master.php.net/note/delete/90113/integrated Del: useless -- https://master.php.net/note/delete/90113/useless Del: bad code -- https://master.php.net/note/delete/90113/bad+code Del: spam -- https://master.php.net/note/delete/90113/spam Del: non-english -- https://master.php.net/note/delete/90113/non-english Del: in docs -- https://master.php.net/note/delete/90113/in+docs Del: other reasons-- https://master.php.net/note/delete/90113 Reject -- https://master.php.net/note/reject/90113 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#152882) next »