Domanda

I made a test appli with Zend and tried to put it online (on an ovh shared server)

Running offline (with WampServer), but not online. Here is the error that I can't solve :

Warning: require_once(/library/Zend/loader/Autoloader.php) [function.require-once]:
failed to open stream: No such file or directory in 
/homez.483/<site>/www/files/<project>/index.php on line 22

Fatal error: require_once() [function.require]: Failed opening required 
'/library/Zend/loader/Autoloader.php' 
(include_path='.
:/homez.483/<site>/www/files/<project>/library
:/homez.483/<site>/www/files/<project>/application
:/homez.483/<site>/www/files/<project>/application/models
:/homez.483/<site>/www/files/<project>/application/forms
:.:/usr/local/lib/php') 
in /homez.483/<site>/www/files/<project>/index.php on line 22

Here is part of the index.php, which is in www/files/project on the server :

// Definition de variable d'environnement
defined('APPLICATION_PATH') || define('APPLICATION_PATH', realpath(dirname(__FILE__) . '/application/'));
defined('LIBRARY_PATH') || define('LIBRARY_PATH', realpath(dirname(__FILE__) . '/library/'));   
defined('MODELS_PATH') || define('MODELS_PATH', realpath(dirname(__FILE__) . '/application/models/'));  
defined('FORMS_PATH') || define('FORMS_PATH', realpath(dirname(__FILE__) . '/application/forms/')); 
defined('APPLICATION_ENV') || define('APPLICATION_ENV', (getenv('APPLICATION_ENV') ? getenv('APPLICATION_ENV') : $applicationEnv));

// Mise en place des répertoires et chargement des classes
set_include_path('.'
. PATH_SEPARATOR . LIBRARY_PATH
. PATH_SEPARATOR . APPLICATION_PATH
. PATH_SEPARATOR . MODELS_PATH
. PATH_SEPARATOR . FORMS_PATH
. PATH_SEPARATOR . get_include_path());
require_once 'Zend/loader/Autoloader.php'; 
Zend_Loader_Autoloader::getInstance()->setFallbackAutoloader(true);

The .htaccess enable PHP5 and UrlRewriting, but nothing to do...

# Config OVH
AddType x-mapp-php5 .php
SetEnv PHP_VER 5
SetEnv REGISTER_GLOBALS 0
SetEnv MAGIC_QUOTES 0
SetEnv SHORT_OPEN_TAG 1

# Règles de réécriture pour Zend Framework
RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule .* index.php
RewriteRule ^robots.txt$ robots.txt [L]

Does anybody got a way to fix this problem ? I guess that's pretty obvious, but I explored many ways found on the web without succes.

Thanks

È stato utile?

Soluzione

Your server's filesystem is case sensitive.

Change this line

require_once 'Zend/loader/Autoloader.php';

to

require_once 'Zend/Loader/Autoloader.php';

The Loader directory begins with a capital "L".

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top