The difference between include,include_once,require,require_once and Requireonceinclude
1. Include,require contains a file at the location where it was called.
2. The Include_once,require_once function is the same as include, but it first verifies that the file is already included. If it is already included, Include_once is no longer executed. Other same as include.
3, require and include the main difference, a, require error, the script will stop running, and include error in the case, the script will continue to execute. b, regardless of the location of the require, the development files will be included in the script that appears require. For example, even if the require is placed in an if statement that evaluates to FALSE, the specified file will still be included.
4, use require_once can solve the problem that the file is overwritten. The Require_once function ensures that the file is included only once. After encountering require_once, the subsequent attempt to include the same file is ignored.
http://www.bkjia.com/PHPjc/1069667.html www.bkjia.com true http://www.bkjia.com/PHPjc/1069667.html techarticle the difference between include,include_once,require,require_once, Requireonceinclude 1, Include,require contains a file at the location where it was called. 2. The Include_once,require_once function ...