私はZendアプリケーションにちょっと困っています...Zendフレームワークで開発した別のサーバーで動作する完全なアプリケーションがあり、ソフトウェアにいくつかの変更を加える必要があります。サーバーからすべてのコードをダウンロードし、必要な構成をすべて行ったのですが、それでもログファイルから次のエラーが発生します。
==> error.log <==
[Fri Jan 11 10:49:53 2013] [error] [client 127.0.0.1] PHP Warning: require_once(Zend/Application.php): failed to open stream: No such file or directory in /home/jonne/Koulu/exercise_project/ProjectFiles/languageTest/application/application.php on line 18
[Fri Jan 11 10:49:53 2013] [error] [client 127.0.0.1] PHP Fatal error: require_once(): Failed opening required 'Zend/Application.php' (include_path='/home/jonne/Koulu/exercise_project/ProjectFiles/languageTest/library:.:/usr/share/php:/usr/share/pear') in /home/jonne/Koulu/exercise_project/ProjectFiles/languageTest/application/application.php on line 18
==> access.log <==
127.0.0.1 - - [11/Jan/2013:10:49:53 +0200] "GET / HTTP/1.1" 500 274 "-" "Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:18.0) Gecko/20100101 Firefox/18.0"
インクルードパスが私には正しいように見えるので、私はこれでいっぱいです?...
パス/home/jonne/Koulu/exercise_project/ProjectFiles/languageTest/library
には、場所を指す2つのシンボリックリンクがあります。
Zend -> /home/jonne/Koulu/exercise_project/ZendFolder/Zend
ZendX -> /home/jonne/Koulu/exercise_project/ZendFolder/ZendX
ZendとZendXの両方のフォルダの内容は次のとおりです。
ゼンド:
drwxrwxrwx 2 jonne jonne 4096 Jan 11 10:12 bin
-rwxrwxrwx 1 jonne jonne 928 Jun 13 2012 composer.json
drwxrwxrwx 3 jonne jonne 4096 Jan 11 10:12 demos
drwxrwxrwx 3 jonne jonne 4096 Jan 11 10:12 externals
drwxrwxrwx 5 jonne jonne 4096 Jan 11 10:12 extras
drwxrwxrwx 2 jonne jonne 4096 Jan 11 10:12 incubator
-rwxrwxrwx 1 jonne jonne 3438 Apr 7 2009 INSTALL.txt
drwxrwxrwx 3 jonne jonne 4096 Jan 11 10:12 library
-rwxrwxrwx 1 jonne jonne 1548 Jan 6 2010 LICENSE.txt
-rwxrwxrwx 1 jonne jonne 12209 Jun 22 2012 README.txt
drwxrwxrwx 3 jonne jonne 4096 Jan 11 10:13 resources
drwxrwxrwx 2 jonne jonne 4096 Jan 11 10:12 src
drwxrwxrwx 4 jonne jonne 4096 Jan 11 10:12 tests
ZendX:
drwxrwxrwx 3 jonne jonne 4096 Jan 11 10:13 Application
drwxrwxrwx 3 jonne jonne 4096 Jan 11 10:13 Console
drwxrwxrwx 4 jonne jonne 4096 Jan 11 10:13 Db
-rwxrwxrwx 1 jonne jonne 1137 Sep 17 11:38 Exception.php
drwxrwxrwx 5 jonne jonne 4096 Jan 11 10:13 JQuery
-rwxrwxrwx 1 jonne jonne 4958 Sep 17 11:38 JQuery.php
これが私のapplication.phpからのコードです:
// Define path to application directory
defined('APPLICATION_PATH')
|| define('APPLICATION_PATH', realpath(dirname(__FILE__) . '/../application'));
// Define application environment
defined('APPLICATION_ENV')
|| define('APPLICATION_ENV', (getenv('APPLICATION_ENV') ? getenv('APPLICATION_ENV') : 'development'));
// Ensure library/ is on include_path
set_include_path(implode(PATH_SEPARATOR, array(
realpath(APPLICATION_PATH . '/../library'),
get_include_path(),
)));
/** Zend_Application */
require_once 'Zend/Application.php';
// Create application, bootstrap, and run
$application = new Zend_Application(
APPLICATION_ENV,
APPLICATION_PATH . '/configs/application.ini'
);
$application->bootstrap()->run();
そしてここにapplication.iniの内容があります
[production]
phpSettings.display_startup_errors = 0
phpSettings.display_errors = 0
includePaths.library = APPLICATION_PATH "/../library"
bootstrap.path = APPLICATION_PATH "/Bootstrap.php"
bootstrap.class = "Bootstrap"
appnamespace = "Application"
;resources.frontController.defaultControllerName = "login"
;resources.frontController.defaultAction = "login"
resources.frontController.controllerDirectory = APPLICATION_PATH "/controllers"
resources.frontController.params.displayExceptions = 0
resources.view = ""
resources.layout.layoutPath = APPLICATION_PATH "/layouts/scripts"
resources.layout.layout = "main"
[staging : production]
[testing : production]
phpSettings.display_startup_errors = 1
phpSettings.display_errors = 1
[development : production]
phpSettings.display_startup_errors = 1
phpSettings.display_errors = 1
resources.frontController.params.displayExceptions = 1
誰か提案はありますか?それでもファイルが見つからないと文句を言うのはなぜですか?!...
Thnx =)