The example in this article describes the method of combining ThinkPHP public configuration files and configuration files in respective projects. Share it with everyone for your reference. The specific implementation method is as follows:
When using ThinkPHP, when laying out the directory, a single entry file is often used to correspond to a project directory. However, when writing configuration files, repeated configuration items are often used in their respective configuration files. This is used The public configuration items will be placed in a public directory.
Specific implementation method:
Use the configuration file feature return array(); which can be defined like this in the configuration file in the respective project:
In this way, you can use the public configuration file in the root directory
I hope this article will be helpful to everyone’s ThinkPHP framework programming.