Home > Backend Development > PHP Tutorial > php如何打印对象的所有属性

php如何打印对象的所有属性

WBOY
Release: 2016-06-06 20:41:25
Original
3028 people have browsed it

有时候在写模块的时候,需要知道可以用哪些属性,怎么样打印出目前该对象拥有的属性?

回复内容:

有时候在写模块的时候,需要知道可以用哪些属性,怎么样打印出目前该对象拥有的属性?

这个?

http://php.net/manual/zh/function.get-object-vars.php
http://php.net/manual/zh/function.get-class-methods.php
http://php.net/manual/zh/function.get-class-vars.php

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template