PHP serialize()/unserialize() module, and a dotlocker 
Author Message
 PHP serialize()/unserialize() module, and a dotlocker

Might be handy to some of those web guys using Ruby backends to PHP
frontends; I've just written PHP::serialize() and PHP::unserialize(),
which cope with Array, Hash, String, Fixnum, Float, NilClass,
False/TrueClass both ways, with a minor limitation on Struct (returned
as Hash for now).

It even distinguishes between Array and Hash on unserialize, despite PHP
not knowing the difference, which puts it one-up on the Perl version I
found.  It doesn't split it into an array of characters like that one
did, either.. :)

I've also written a small dotlocking class which should be functionally
identical to the dotlocking implementation ecartis uses, which might
come in handy for manipulating mbox files, ecartis userfiles, and
anything else which might use dotlocking.

If anyone has a desperate need for them, mail me privately.  I'll
probably RAA them soon, but knowing me that might not even be this year
;)

--



Fri, 18 Nov 2005 09:40:40 GMT  
 PHP serialize()/unserialize() module, and a dotlocker

Quote:
> Might be handy to some of those web guys using Ruby backends to PHP
> frontends; I've just written PHP::serialize() and PHP::unserialize(),
> which cope with Array, Hash, String, Fixnum, Float, NilClass,
> False/TrueClass both ways, with a minor limitation on Struct (returned
> as Hash for now).

Struct's are now handled, along with (in theory) any other PHP object
instance, which can be mapped to native Ruby objects or an automatically
generated Struct.

It's available at http://www.aagh.net/files/ruby/php_serialize.rb

--



Fri, 18 Nov 2005 19:13:59 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. perl/php unserialize module

2. Problems passing arrays (serialize, unserialize, etc) - help!!!

3. serialize and unserialize

4. import of PHP serialized data

5. unserialize array session value

6. Code to unserialize Perl's Storable format?

7. Is PHP is running as Module or CGI?

8. External PHP module - linking problem

9. PHP as Apache Module and Static Program

10. Pb php4/apache2 avec index.php en module

11. compiling PHP with --enable-debug disables module

12. PHP HTML module?

 

 
Powered by phpBB® Forum Software