mirror of
https://github.com/sigmasternchen/php-doc-en
synced 2025-03-15 16:38:54 +00:00
Where included files are looking for
# check my English please git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@150852 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
parent
f24edb2d9c
commit
5b8143ed9e
1 changed files with 10 additions and 1 deletions
|
@ -1,5 +1,5 @@
|
|||
<?xml version="1.0" encoding="iso-8859-1"?>
|
||||
<!-- $Revision: 1.86 $ -->
|
||||
<!-- $Revision: 1.87 $ -->
|
||||
<chapter id="control-structures">
|
||||
<title>Control Structures</title>
|
||||
|
||||
|
@ -1237,6 +1237,15 @@ require ('somefile.txt');
|
|||
a missing file to halt processing of the page. <function>include</function> does
|
||||
not behave this way, the script will continue regardless. Be sure to have an
|
||||
appropriate <link linkend="ini.include-path">include_path</link> setting as well.
|
||||
Be warned that parse error in required file doesn't cause processing halting.
|
||||
</simpara>
|
||||
<simpara>
|
||||
Files for including are first looked in include_path relative to the current working directory
|
||||
and then in include_path relative to the directory of current script. E.g. if your include_path
|
||||
is <literal>.</literal>, current working directory is <filename class="directory">/www/</filename>,
|
||||
you included <filename>include/a.php</filename> and there is <literal>include "b.php"</literal>
|
||||
in that file, <filename>b.php</filename> is first looked in <filename class="directory">/www/</filename>
|
||||
and then in <filename class="directory">/www/include/</filename>.
|
||||
</simpara>
|
||||
<simpara>
|
||||
When a file is included, the code it contains inherits the
|
||||
|
|
Loading…
Reference in a new issue