Unmarshal object with PHP

Hi,

Is there any implamentation of something like Marshal.dump in PHP? Or
any implementation that is easily readable, so I could rewrite it into
PHP? :slight_smile: (I can’t figure out what’s going on in C files from ruby
core :wink:

Thanks,
Peter

On 8/20/07, [email protected] [email protected] wrote:

Hi,

Is there any implamentation of something like Marshal.dump in PHP? Or
any implementation that is easily readable, so I could rewrite it into
PHP? :slight_smile: (I can’t figure out what’s going on in C files from ruby
core :wink:

What you need to figure out (or what you might need to tell us) is if
you
mean you want to do some cross-language serialization based on Marshal,
or
if you’re just looking for a PHP equivalent of Marshal (but not
necessarily cross language compatible). Given the topic of this list,
I’ll
assume the former for now! Someone else might be able to help with an
implementation, but otherwise you might find this rather useful:

http://redhanded.hobix.com/inspect/theMarshWalker.html

Cheers,
Peter C.
http://www.rubyinside.com/

On Aug 19, 2007, at 16:24, [email protected] wrote:

Is there any implamentation of something like Marshal.dump in PHP? Or
any implementation that is easily readable, so I could rewrite it into
PHP? :slight_smile: (I can’t figure out what’s going on in C files from ruby
core :wink:

http://www.aagh.net/projects/ruby-php-serialize

2007/8/20, [email protected] [email protected]:

Hi,

Is there any implamentation of something like Marshal.dump in PHP? Or
any implementation that is easily readable, so I could rewrite it into
PHP? :slight_smile: (I can’t figure out what’s going on in C files from ruby
core :wink:

If you can switch formats, YAML might be easier:

http://www.google.com/search?q=yaml+php

Kind regards

robert

On Aug 20, 2007, at 05:45, Piotr Sarnacki wrote:

application to find out if user is logged in.

If there is no easy way to do this I’d have to change session
behaviour a little bit… :]

That’s probably optimal. Porting Ruby’s marshal format to PHP is
going to take you longer than using PHP serialize instead of marshal
on your session data.

Thanks for replies :slight_smile:

On Aug 20, 3:30 am, Eric H. [email protected] wrote:

http://www.aagh.net/projects/ruby-php-serialize

I should specify more precisely :slight_smile: I need something like Ruby PHP
serializer, but “the other way”. (PHP Ruby Marshalizer? :wink: )

Session data in Rails is marshaled and I want to read it in PHP
application to find out if user is logged in.

If you can switch formats, YAML might be easier:

Yes, YAML would be much easier :slight_smile: But as you see I can’t use it.

If there is no easy way to do this I’d have to change session
behaviour a little bit… :]

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs