Session string (a comment)

From: Date: Tue, 27 Feb 2001 13:46:44 +0000
Subject: Session string (a comment)
Groups: php.dev 
Request: Send a blank email to php-dev+get-47615@lists.php.net to get a copy of this message
Hey, I've recently developed a parser which understands PHP serialized objects (both read and write), and therefore I had to understand how the objects are serialized in PHP - 100%. This is only meant as a comment. Feel free to shrug it off. 1. The way associative arrays are implemented bites. The counting up which occurs in the array to figure out what is associative and what is not should be implemented fully that way instead of a mix. 2. Data comes in tuples of two: <myvar-decl><myvar-data>. Meaning: s:12:"creationTime";i:974886470; The two tuples are always seperated by a ";" UNLESS the datatype is an array. This makes tokenizing a bitch basically. Change: s:"5":"types";a:0:{}s:7:..... To: s:"5":"types";a:0:{};s:7:..... ^ (Same thing with Objects inside objects I think, not checked) Just my $0.02 Soeren Staun-Pedersen - Staun@SunSITE.dk ------ "The internet is full, beat it" - Me.

« previous php.dev (#47615) next »