Home > Backend Development > PHP Tutorial > thinkphp autoload namespace custom namespace

thinkphp autoload namespace custom namespace

WBOY
Release: 2016-07-25 08:44:42
Original
956 people have browsed it

In the process of using thinkPHP, some custom class libraries and third-party class libraries need to find a suitable location to place them. It does not feel good to put them in the system's default org folder, which destroys the native directory of thinkPHP.

I took a look at the official manual and found that you can customize the namespace of the class library in the module or application configuration file.

However, one thing to note when using it is that your custom namespace name needs to correspond to your folder name and cannot be changed.

Then test it

The above is the entire content of this article, I hope you all like it.

Customize, thinkphp, autoload


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