我已经使用http://framework.zend.com/manual/en/zend.http.user-agent.html#zend.http.user-agent.quick-start上的文章包含了所有参数,但它显示了一个异常,无法解析插件"useragent";没有与该名称对应的插件。我的代码是:
application.ini中的所有配置
resources.useragent.storage.adapter = "Session"
resources.useragent.wurflapi.wurfl_api_version = "1.3.1"
resources.useragent.wurflapi.wurfl_lib_dir = APPLICATION_PATH "/../library/wurfl-php-1.3.1/WURFL/"
resources.useragent.wurflapi.wurfl_config_array.wurfl.main-file = APPLICATION_PATH "/../data/wurfl/wurfl.xml"
resources.useragent.wurflapi.wurfl_config_array.wurfl.patches[] = APPLICATION_PATH "/../data/wurfl/web_browsers_patch.xml"
resources.useragent.wurflapi.wurfl_config_array.persistence.provider = "file"
resources.useragent.wurflapi.wurfl_config_array.persistence.dir.dir = APPLICATION_PATH "/../data/wurfl/cache/"已加载从http://sourceforge.net/projects/wurfl/files/WURFL%20PHP/1.1/wurfl-php-1.1.tar.gz/download版本1.3.1下载的文件Root_DIR/library/wurfl-php-1.3.1
使用应用程序创建了数据文件夹,并使用Root_DIR/ data /wurfl /chache web_browsers_patch.xml wurfl.xml进行了更新
我错过了什么??提前谢谢。
发布于 2012-02-28 21:26:19
这是由于版本问题。我在更新zend库的版本后解决了这个问题。它支持zend V 1.11及更高版本。在这个成功的实现之后,我仍然得到了一个异常,比如:严格的标准: Application_Helper_MobileContext::addActionContext()的声明应该与第3行/storage/projects/gomotive/application/helpers/MobileContext.php中的Zend_Controller_Action_Helper_ContextSwitch::addActionContext()的声明兼容
还通过在父方法中传递默认参数值解决了这个问题。检查Declaration of Methods should be Compatible with Parent Methods in PHP下面的链接
发布于 2012-07-05 12:49:28
我的解决方案是将Zend框架包含到您的库文件夹中。我也面临着同样的问题,偶然间我将Zend framework v1.11包含到库中,一切工作正常
https://stackoverflow.com/questions/8983330
复制相似问题