Php – (PHP)(XAMPP) how do i fix this error: Fatal error: require_once(): Failed opening required ‘PEAR.php’ (include_path=’.;C:\php\pear’)

PHP

when i run this: http://localhost/EventCalenderPHP/Sourcescode/demo.php

i get this error:

Warning: require_once(PEAR.php): failed to open stream: No such file or directory in C:\xampp\htdocs\EventCalenderPHP\Sourcescode\includes\Mail.php on line 46

Fatal error: require_once(): Failed opening required 'PEAR.php' (include_path='.;C:\php\pear') in C:\xampp\htdocs\EventCalenderPHP\Sourcescode\includes\Mail.php on line 46

https://github.com/cherishsantosh/EventCalenderPHP

Best Answer

Small mistake: There is no folder named "Sourcescode".
Look closely, there is a space in between.

Give the correct address when you're including the file. That'll fix the error.

Since there is no folder named "Sourcescode", php is unable to find the Mail.php file.

enter image description here

Related Topic