Bonjour,
Je débute tout juste sous Zend Framework. Je suis votre tutoriel "Débuter avec Zend Framework 1.5 (approche MVC)", mais j'ai des soucis dès le début.
Dans la partie 2 - Organisation, j'ai fait la structure de mes répertoires, j'ai extrait les librairies de mon archives vers mon appli, j'ai crée le fichier .htaccess, et modifié la directive AllowOverride à All. Ensuite j'ai crée le fichier index.php.
Lors de votre tuto, vous dites d'essayer d'atteindre http://localhost/tutoriel-zf/ , et je devrais avoir un message du type :
"Fatal error: Uncaught exception 'Zend_Controller_Dispatcher_Exception' with message 'Invalid controller specified (index)' in..."
Sauf que j'obtiens:
"Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.
Please contact the server administrator, admin@localhost and inform them of the time the error occurred, and anything you might have done that may have caused the error.
More information about this error may be available in the server error log."
Si je supprime ce fichier .htaccess , je peux accéder à ma page, sauf que j'ai un warning (j'ai du modifier dans index.php "Zend_Loader::registerAutoload();" par "require_once 'Zend/Loader/Autoloader.php'; $autoloader = Zend_Loader_Autoloader::getInstance(); $autoloader->setFallbackAutoloader(true);" pour ne plus avoir ce warning vu que je travail avec la version 1.9.6 de Zend Framework).
J'ai quand quand même continué à développer. J'ai crée mon IndexController, et ensuite vous demandez de tester différentes url. Voici les résultats que j'obtiens quand je les test :
- http://localhost/tutoriel-zf/public : Index of /tutoriel-zf/public avec l'arborescence du répertoire public (css, images, js),
- http://localhost/tutoriel-zf/public/index/ajouter modifier et supprimer : Not Found The requested URL /tutoriel-zf/public/ajouter was not found on this server.
L'environnement utilisé :
Zend Framework 1.9.6
Wamp Server 2.0
Vous trouverez en ci joint mon projet tutoriel-zf et mes fichier httpd.conf et php.ini ICI .
En espérant une réponse rapide de votre part.
Cordialement,
Grégory SEVES.
Partager