Failed opening required FAIL PHP HELP!!

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
bestrong
Forum Newbie
Posts: 2
Joined: Fri Apr 24, 2009 12:44 pm

Failed opening required FAIL PHP HELP!!

Post by bestrong »

Hello everyone!

I am having some trouble including the pear mail.php file

my code is

Code: Select all

 
error_reporting(E_ALL);
ini_set('display_errors', '1');
require_once "Mail.php";
 
...more code PHP PHP etc
 
This products the error message

Code: Select all

 
Warning: require_once(Mail.php) [function.require-once]: failed to open stream: No such file or directory in /var/www/vhosts/bluebeanstalk.com/httpdocs/admin/sendmail.php on line 7
 
Fatal error: require_once() [function.require]: Failed opening required 'Mail.php' (include_path='.:/usr/share/pear/') in /var/www/vhosts/bluebeanstalk.com/httpdocs/admin/sendmail.php on line 7
 
 
The include path is correct (include_path='.:/usr/share/pear/) and there are the Mail.php, PEAR.php, etc in that folder.

I have already tried removing the trailing slash on include_path='.:/usr/share/pear/, and that did nothing different.

Also, this is not a case sensitive error...

Thanks so much, :wink:

Ben
Last edited by Benjamin on Wed May 20, 2009 2:11 pm, edited 1 time in total.
Reason: Changed code type from text to php.
User avatar
Darhazer
DevNet Resident
Posts: 1011
Joined: Thu May 14, 2009 3:00 pm
Location: HellCity, Bulgaria

Re: Failed opening required FAIL PHP HELP!!

Post by Darhazer »

Are you sure that there should be a ':' in the include_path
IMHO it should be

Code: Select all

'/usr/share/pear/'
Post Reply