清除require载入的文件 php

WBOY
Release: 2016-06-02 11:30:53
Original
1848 people have browsed it

php

有一系列的外部文件,一个文件就是一个类,类的结构都是一样的,只是具体的方法代码有所不同。

循环载入这些类文件的时候,会报错can't redecare XXX,因为类的方法名都是一样的,所以要先清除前面
载入过的文件,怎样清除!?有require,但好像没有unrequire或者derequire啊~~~

我搜了一阵都没有人提过这个问题,只好来问一下了。

Related labels:
php
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