Not sure what the process is for serializing a child class that is implementing the Serializable interface, the parent class no longer retains the data it was once serializing. Is there a step I am missing?
class A { private $aVar = "test"; } class B extends A implements Serializable { private static $bVar = "tset"; public function serialize() { return serialize($this->bVarself::$bVar); } public function unserialize($serialized) { $this->bVarself::$bVar = unserialize($serialized); } } $s = serialize(new B()); $u = unserialize($s);