Include Paths
An Include Path is a location which connects elements created in external projects/libraries to the active project.
Projects/libraries added to a project's Include Path affect the following:
Debugging - If a 'require'/'include' call calls a file that exists outside of the active project and its location is specified in a 'Relative' way (see below), you must add its location to the project's Include Path in order for the correct file to be called during debugging.
Code Assist - Adding projects/libraries to a project's Include Path will make elements defined within the included projects/libraries available as Code Assist options to the project.
In 'include'/'require' calls, file locations can be defined in three ways:
Absolute - The exact file location is specified (e.g. C:\Documents and Settings\MyProject\myfolder\a.php).
Relative to the Current Working Directory - File names preceded with a "./" or a "../" These will only be searched for relative to the PHP 'Current Working Directory'. You can find out the location of your Current Working Directory by running the command "echo getcwd()".
Relative
Path - Only the file name or partial
path is specified (e.g. /myfolder/a.php). In this case, PDT will
search for the file's path in the project's Include Path and in the project
itself.
If the path of the file being searched for exists in more than one
location, the file that is called will be the first one PDT encounters
during the search process.
The order in which PDT searches for
the file's path is as follows:
The order specified in the "debug target"
(the first file to be debugged) project's Include Path. If a project specified
in the Include Path refers to other projects/libraries in its own Include
Path, the file path will be searched for there before the search process
continues.
See Adding
Elements to a Project's Include Path for more on defining the order
of projects / libraries in a project's Include Path.
The "debug target" file's project.
See http://il2.php.net/manual/en/function.include.php for more on PHP's search mechanism.
|
|
|
|
|
Related Links: |
|
|
|