How to convert a child instance to parent class and the reverse in PHP?

Posted by symfony on Stack Overflow See other posts from Stack Overflow or by symfony
Published on 2010-03-21T05:09:57Z Indexed on 2010/03/21 5:11 UTC
Read the original article Hit count: 153

Filed under:
|
$child_instance = (childClass)$parent_instance;
$parent_instance = (parentClass)$child_instance;

Or is it possible?

© Stack Overflow or respective owner

Related posts about php

Related posts about class