note 35185 added to function.unserialize

From: Date: Fri, 22 Aug 2003 14:27:11 +0000
Subject: note 35185 added to function.unserialize
Groups: php.notes 
Request: Send a blank email to php-notes+get-54873@lists.php.net to get a copy of this message
I've head problems to unserialize data read back from file (v4.3.3, Windows). Problem turned out to not be unserialize, but the actual filereading (for details see Bug #25185): The way you save and load the data must match. Windows does line termination translation (e.g. \n -> \r\n). To avoid this you must write and read using open mode 'wb'. ---- Manual Page -- http://www.php.net/manual/en/function.unserialize.php Edit Note -- http://master.php.net/manage/user-notes.php?action=edit+35185 Delete Note -- http://master.php.net/manage/user-notes.php?action=delete+35185&report=yes Reject Note -- http://master.php.net/manage/user-notes.php?action=reject+35185&report=yes

« previous php.notes (#54873) next »