Reply to Re: figure out members of an object?

Your name:

Reply:


Posted by NC on 10/03/05 06:31

www.douglassdavis.com wrote:
>
> Say I am retrieving an object from a function...
....
> Now, there could be two "types" of objects returned, with two distinct
> sets of members.
>
> say one type has a member "prefix" and one has a member "prefix1"
>
> my question is, how can I figure out which type the function has
> returned?

Use get_object_vars() to obtain an associative array of defined object
properties for the returned object. Alternetively, use get_class() to
see the type of the returned object. For more information, see the
Manual:

http://www.php.net/get_object_vars
http://www.php.net/get_class

Cheers,
NC

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация