一切都在1.9.6正常工作.我改为1.10,现在基本上每个应用程序资源都有很多警告.
看起来ZF正在我设置的"自定义资源"路径中寻找应用程序资源:pluginpaths.App_Application_Resource ="应用程序/应用程序/资源.有什么方法可以避免这种情况!"(提前感谢您的支持时间)
application.ini: resources.locale.default = sq_AL resources.frontController.controllerDirectory = APPLICATION_PATH "/controllers" resources.layout.layoutPath = APPLICATION_PATH "/layouts/scripts" resources.frontController.throwExceptions = 0 ; VIEW & HTML Markup Options resources.view.doctype = "HTML5" resources.view.language = "en" resources.view.setSeparator=" - " resources.view.helperPath.View_Helper = APPLICATION_PATH "/views/helpers" resources.view[] = ; custom resources **pluginpaths.App_Application_Resource = "App/Application/Resource"**
在库/ App/Application/Resource/Cache我有一个类"App_Application_Resource_Cache扩展Zend_Application_Resource_ResourceAbstract",我需要缓存.问题是,现在在第一页我有很多警告,如:
Warning: is_readable() [function.is-readable]: open_basedir restriction in effect. File(/usr/share/php/App/Application/Resource/Locale.php) is not within the allowed path(s): (/var/home//httpdocs:/tmp:/var/home/) in /var/home//library/Zend/Loader.php on line 190 Warning: is_readable() [function.is-readable]: open_basedir restriction in effect. File(/usr/lib64/php/modules/App/Application/Resource/Locale.php) is not within the allowed path(s): (/var/home//httpdocs:/tmp:/var/home/) in /var/home//library/Zend/Loader.php on line 190 Warning: is_readable() [function.is-readable]: open_basedir restriction in effect. File(/usr/share/php/App/Application/Resource/Frontcontroller.php) is not within the allowed path(s): (/var/home//httpdocs:/tmp:/var/home/) in /var/home//library/Zend/Loader.php on line 190 Warning: is_readable() [function.is-readable]: open_basedir restriction in effect. File(/usr/lib64/php/modules/App/Application/Resource/Frontcontroller.php) is not within the allowed path(s): (/var/home//httpdocs:/tmp:/var/home/) in /var/home//library/Zend/Loader.php on line 190 Warning: is_readable() [function.is-readable]: open_basedir restriction in effect. File(/usr/share/php/App/Application/Resource/Layout.php) is not within the allowed path(s): (/var/home//httpdocs:/tmp:/var/home/) in /var/home//library/Zend/Loader.php on line 190 Warning: is_readable() [function.is-readable]: open_basedir restriction in effect. File(/usr/lib64/php/modules/App/Application/Resource/Layout.php) is not within the allowed path(s): (/var/home//httpdocs:/tmp:/var/home/) in /var/home//library/Zend/Loader.php on line 190 Warning: is_readable() [function.is-readable]: open_basedir restriction in effect. File(/usr/share/php/./views/helpers/Doctype.php) is not within the allowed path(s): (/var/home//httpdocs:/tmp:/var/home/) in /var/home//library/Zend/Loader.php on line 190 Warning: is_readable() [function.is-readable]: open_basedir restriction in effect. File(/usr/lib64/php/modules/./views/helpers/Doctype.php) is not within the allowed path(s): (/var/home//httpdocs:/tmp:/var/home/) in /var/home//library/Zend/Loader.php on line 190 Warning: is_readable() [function.is-readable]: open_basedir restriction in effect. File(/usr/share/php/./views/helpers/HeadMeta.php) is not within the allowed path(s): (/var/home//httpdocs:/tmp:/var/home/) in /var/home//library/Zend/Loader.php on line 190 Warning: is_readable() [function.is-readable]: open_basedir restriction in effect. File(/usr/lib64/php/modules/./views/helpers/HeadMeta.php) is not within the allowed path(s): (/var/home//httpdocs:/tmp:/var/home/) in /var/home//library/Zend/Loader.php on line 190 Warning: is_readable() [function.is-readable]: open_basedir restriction in effect. File(/usr/share/php/./views/helpers/HeadTitle.php) is not within the allowed path(s): (/var/home//httpdocs:/tmp:/var/home/) in /var/home//library/Zend/Loader.php on line 190
万一有人需要它,在引导程序中这是Autoload-er
'App', 'basePath' => dirname(__FILE__), ) ); return $autoloader; }
Al-Punk.. 7
@Pekka
set_include_path(implode(PATH_SEPARATOR, array( realpath(APPLICATION_PATH . '/../library'), //get_include_path(), )));
通过注释掉get_include/path()
(在index.php中)我已经从/ usr/share/php /中省略了include.警告消失了.
感谢您的(精湛)帮助!
显然,PLESK和CentOS存在一个问题,即无法从虚拟主机访问PHP的包含路径!
@Pekka
set_include_path(implode(PATH_SEPARATOR, array( realpath(APPLICATION_PATH . '/../library'), //get_include_path(), )));
通过注释掉get_include/path()
(在index.php中)我已经从/ usr/share/php /中省略了include.警告消失了.
感谢您的(精湛)帮助!
显然,PLESK和CentOS存在一个问题,即无法从虚拟主机访问PHP的包含路径!
好吧,这个问题已在评论中排序:)将此问题作为答案,您可以接受以解决问题.
您不能从PHP脚本访问该路径,请查看错误消息(/ usr/share不在允许的目录列表中).将包含路径更改为(我猜)/ var/home/library/Zend/
应该解决它.
显然,PLESK和CentOS存在一个问题,即无法从虚拟主机访问PHP的包含路径!
我认为这open_basedir
取决于禁止虚拟主机访问它们之外的任何内容的设置,它不是特定于操作系统的.无论如何,很高兴它排序了!