Re: [PHP] best way to set up an include path for a multi-level project?
[email protected] (John Black)
| Newsgroups | php.general |
|---|---|
| Message-ID | <[email protected]> |
On 03/16/2010 08:50 PM, John Black wrote: > So I just set $include = './include/abc/def/' at the top of the correction, I set $include to the relative path of the include directory and then use it like this: $include = '../../include/'; require $include.'abc/file1.php'; require_once $include.'abc/def/file2.php'; require_once $include.'file3.php'; Still works the same way but since all my include files are in include or some sub directory of it this works perfect. -- John Vorurteil ist das Kind von Ignoranz. [William Hazlitt]