#23543 [Opn->Fbk]: unserialize on object fails when string is loaded with file()
| From: | alan_k@php.net | Date: | Thu, 08 May 2003 12:19:43 +0000 |
| Subject: | #23543 [Opn->Fbk]: unserialize on object fails when string is loaded with file() | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-39297@lists.php.net to get a copy of this message | ||
ID: 23543
Updated by: alan_k@php.net
Reported By: tbrandl at barff dot de
-Status: Open
+Status: Feedback
Bug Type: Strings related
Operating System: Win 2k
PHP Version: 4.3.1
New Comment:
Not enough information was provided for us to be able
to handle this bug. Please re-read the instructions at
http://bugs.php.net/how-to-report.php
If you can provide more information, feel free to add it
to this bug and change the status back to "Open".
Thank you for your interest in PHP.
can you provide a fully working example illustrating this issue?
Previous Comments:
------------------------------------------------------------------------
[2003-05-08 07:10:21] tbrandl at barff dot de
this fails (output is null):
$string = unserialize(implode("", file("serialized_Obj.dat")));
print_r($string) == null;
this works:
fopen("serialized_Obj.dat");
$string = unserialize(fread($fh, ...));
print_r($string) == the original object.
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=23543&edit=1