I am working with doctrine 2 and zend framework 1.11. Public properties are discouraged in Doctrine 2, so I made my entity properties private. However I have just learned th
Create a method how this in your class:
function serialize(){ return json_encode(get_object_vars ($this)); }