Serialize - unserialize array problem

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
neds75
Forum Newbie
Posts: 3
Joined: Thu Jul 13, 2006 4:50 am

Serialize - unserialize array problem

Post by neds75 »

I have problem with serialize/unserilize array of strings.

Actually, it works perfect when I do serialize/unserialize on computers with same OS(linux windown). But when I try to serialize data on linux and unserialize that data on windows(or contrary), I get error(notice). Serialized data are saved in file, no GET/POST or any other data, so magic gpc and magic gpc rantime is not problem(altought it is OFF on both computers).
addslashes/strip slashes is not problem too.

I lost few hours searchng net for this problem, but I wasn't lucky to find anythting interesting.

Is this bug, or maybe problem in some special characters like new lines/CR and so on? If so what woudl be the sollution.

Thanks
User avatar
Burrito
Spockulator
Posts: 4715
Joined: Wed Feb 04, 2004 8:15 pm
Location: Eden, Utah

Post by Burrito »

I've never heard of anythign like this being OS specific. You say that ser / un works fine if done on both machines. Why don't you try serializing a few small arrays from both machines then compare the strings to see if/how they differ.
Post Reply