[PHP] include details. The order in which include files are loaded is: first, find the file in the relative include_path of the current working directory, and then the order in which inclu include files are loaded in the directory where the current
Require and include are almost the same, except for different methods of handling failures. Require generates an E_COMPILE_ERROR-level error when an error occurs. In other words, it will cause the script to stop and include will only generate a
Include File Loading SequenceThe order of searching for contained files is:
First, search for the corresponding include_path in the current working directory,Find the corresponding directory named include_path.For example, include_path is ., the
Require
Require and include are almost exactly the same, in addition to handling failures differently. Require generates an E_COMPILE_ERROR level error when an error occurs, in other words, causes the script to abort and the include only generates a
Joe Brockmeier briefly introduces the PHP scripting language, discusses the origin, performance, and application Platform of PHP. A simple example of a PHP script illustrates its basic syntax and usage.
If you are working on web-based development,
PHP Tutorial Configuration Chinese Narration
Let's see what you see, php.ini.
[PHP]
;;;;;;;;;;;; WARNING;;;;;;;;;;;;; This is the default settings file for new PHP installations.; By default, PHP installs itself with a configuration suitable for;
The working mechanism of PHP auto load _ autoload. When using the php oo mode to develop a system, we usually get used to storing the implementation of each class in a separate file, which makes it easy to reuse classes, at the same time, in the
Include Load file order
The order in which to look for include files is:
First, in the current working directory of the relative include_path under the search,Then look under the include_path of the directory where the script is currently
PHP Tutorial Require/include sequence
In a large Web project, Include_path is fundamental to a modular design (and of course, there are many autoload-based designs that do not affect this article), but precisely because of Include_path, It often
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.