0

I have an error that happens only on my host server, on my local environment not:

Fatal error: require_once() [function.require]: Failed opening required '\Audero\Loader\AutoLoader.php' (include_path='.:/usr/share/pear:/usr/share/php:/home/httpd/vhosts/webox-it.com/ofrom.webox-it.com/modules/Concordancier....\lib') in /home/httpd/vhosts/webox-it.com/ofrom.webox-it.com/modules/Concordancier/data_manager.php on line 1670

Here is my code:

set_include_path(get_include_path() . PATH_SEPARATOR . __DIR__ . '/../../lib/');
require_once 'Audero\Loader\AutoLoader.php';
spl_autoload_register('Audero\Loader\AutoLoader::autoload');
    // Extract the chunk and save it on the hard disk
    try {

        $extractor = new \Audero\WavExtractor\AuderoWavExtractor($inputFile);
        $extractor->saveChunk($start, $end, $outputFile);
...

Files structure: /lib/Audero/Loader/Autoloader.php

Calling file emplacement: /modules/Concordancier/data_manager.php

In my local environment there's no problem, php can load the autoloader, but in the prod server it does not. The source files structure is exactly the same as the local one, and the relative path looks correct. The php version in prod is 5.3.27 so it should work ?

Any idea ?

Funk Forty Niner
  • 74,450
  • 15
  • 68
  • 141
Bibou
  • 11
  • 1
  • By taking a quick look at the include path provided in the error message it says the following: `/home/httpd/vhosts/webox-it.com/ofrom.webox-it.com/modules/Concordancier....\lib`. To me the last part `/Concordancier....\lib` seems wrong. Like the slashes isn't added on the production server. – AnotherGuy Jan 31 '15 at 16:11
  • Sorry, the editor removed the slashes. The real path from the error message is: include_path='.:/usr/share/pear:/usr/share/php:/home/httpd/vhosts/webox-it.com/ofrom.webox-it.com/modules/Concordancier/../../lib/ – Bibou Feb 02 '15 at 00:02
  • Have you made sure the system user php uses has read access. Sometimes if files are uploaded using ftp or similar tools, they are given mininmum rights to help security. – AnotherGuy Feb 02 '15 at 09:55

0 Answers0