get_object_vars() vs. cast to array
Posted
by scribu
on Stack Overflow
See other posts from Stack Overflow
or by scribu
Published on 2010-03-24T23:33:07Z
Indexed on
2010/03/24
23:33 UTC
Read the original article
Hit count: 87
php
Are there any differences between get_object_vars($obj)
and (array) $obj
?
Both seem to return the public properties of the object.
Which is better?
© Stack Overflow or respective owner