I have several separate websites that live in separate directories. For includes that they have in common, I have it living in the root directory where the rest of them live.
user@hostname:/var/www$ ls
website_1 website_2 website_3 common_files
I want to include a Zend package, so I have my include path
ini_set("include_path", get_include_path() . ":/var/www/common_files/Zend");
require_once("Mail.php");
Mail.php
loads okay, but then somewhere in there is this line
require_once 'Zend/Mail/Transport/Abstract.php';
which gives this error
Warning: require_once(Zend/Mail/Transport/Abstract.php): failed to open stream: No such file or directory in var/www/common_files/Zend/Mail.php on line 26
So php doesn't recursively descend into the directory structure of the include paths. Do I have to move Zend into each website direcory, spell out the path to every include, or what?
BTW Abstract does exist:
user@host:/var/www/common_files/Zend$ tree -d
...
`-- Mail/Transport
|-- Mail/Transport/Abstract.php
|-- Mail/Transport/Exception.php
|-- Mail/Transport/Sendmail.php
`-- Mail/Transport/Smtp.php
9 directories, 32 files