I’m experiencing some weirdness trying to setup PEAR on my development machine (Windows XP).
The process is simple enough and everything makes sense, but I’m trying to use one of the installed packages which calls on the PEAR.php file and am getting:
Failed opening required 'PEAR.php' (include_path='.;C:\Program Files\PHP\PEAR')
It’s a pretty straightforward error to get assuming the file/path doesn’t exist, except I’ve checked and double checked – it absolutely does – right down to capitalisation (which I know doesn’t matter on Windows normally but still…)
What can I possibly have overlooked that means the file can’t be opening?
Just to re-iterate, the file/dir DEFINITELY exists as C:\Program Files\PHP\PEAR\PEAR.php – and I have also tried:
- forward slashes
- short dir names (Progra~1)
- all lower case (even though the files are as is) and even setting the include path to
ONLY that directory. - test.php in same directory
- test.php in c:\ and with include path set to c:\ and just \
PHP (5.2.6) is NOT running in safe mode, and the web server is Apache 2.
Maybe your php configuration has
open_basedirset? If so, set it’s value to none.