0
votes

My script is dying at

require_once "Mail.php"

I have configured php.ini correctly. It runs from the command line but the exact same script dies in my browser. I'm guessing it's something simple but I can't quite work out what. Running Centos 5

Edit:

Fatal error: require_once() [function.require]: Failed opening required 'Mail.php' (include_path='.:/usr/share/pear:/local/PEAR/')

which is strange

under /usr/share/pear

I have

-rw-r--r-- 1 root root 8934 Jul 20 2007 Mail.php

1
Do you have any logs available? In your browser the script has been executed with different access rights. Usually it's path-issue or access rights. We are able to help you better if you can provide some logs here. - hade
I'm not very good at sysadmin. Which logs should I be looking at? - deltanovember
Is the PHP your using at the Cmd Line the same PHP that is set to run from Apache? Remember that they are two separate things PHP and Apache. - Jake N
What kind of error you get in the browser ? You should check the include_path if it's pointing at PEAR files. - Radoslav Georgiev

1 Answers

3
votes

PHP has two different .ini files, one for the server module and one for the cli. They must have the same configuration options. Maybe you are missing the pear path in the server module!