Home > Backend Development > PHP Tutorial > 关于PHP类调用类的问题

关于PHP类调用类的问题

WBOY
Release: 2016-06-23 14:27:00
Original
801 people have browsed it

具体看图:


回复讨论(解决方案)

在t2的contruct里new一个t1类。作单例。
然后在t2中 this->obj->t1方法()

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