I'm trying to figure out if it's possible to serialize COM objects in PHP so I can store them in a user's session. (While in general I know it's a bad idea to store COM objects in sessions, I've got one that has been specifically designed for this.) I had hoped to just be able to serialize() the object, but the output of that is too small to be correct.
I've thought that I might be able to com_addref() each object and try to build my own session management, but wanted to check first if I was missing an easier way. Any ideas?