Mismatch
Status: Beta
Brought to you by:
mpalmerlee
Hello!
I tried to use your lib, and it works perfectly. Just one issue: if you will try to deserialize some string and serialize it back - it may be not the same.
The main issue is in the order of hash keys: the used C# Hashtable does not store order, but order may be important for PHP app.
Here is the sample:
var s = new PhpSerializer(); var origin = ""; origin = @"a:4:{i:0;s:5:""/home"";i:1;s:2:""12"";i:2;s:5:""apple"";i:3;a:4:{s:4:""Mike"";i:12;s:4:""John"";i:79;s:5:""Tonya"";i:-3;s:4:""Anna"";s:5:""smoke"";}}"; Assert.AreEqual(origin, s.Serialize(s.Deserialize(origin)));
I have attached my solution, plz, review it :)