Home >Backend Development >PHP Tutorial >PHP面向对象(一)

PHP面向对象(一)

WBOY
WBOYOriginal
2016-06-13 12:01:14889browse

PHP面向对象(1)
如果子类没有构造方法,就会调用父类的构造方法。如果子类有自己的构造方法,就会调用自己的构造方法。子类的构造方法覆盖了父类的构造方法。在静态方法里面使用this关键字会出错。

Statement:
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