【发布时间】:2010-03-16 09:38:27
【问题描述】:
我在 WAMP 2.0 中使用 symfony 1.4 的 setFlash 和 hasFlash 方法
在本地使用我的 frontend_dev 应用程序,一切正常。
但是在生产环境中,我的测试$this->forward404Unless($user->hasFlash('resultsArray')); 失败了。
我认为 Flash 方法默认启用。请问我该怎么做才能让它工作?
编辑:我发现了一条有趣的错误消息。
这是我的 filters.yml 文件
# You can find more information about this file on the symfony website:
# http://www.symfony-project.org/reference/1_4/en/12-Filters
rendering: ~
security: ~
# insert your own filters here
cache: ~
flash: ~
execution: ~
在 frontend_prod.log 中,我有:
3 月 16 日 05:57:42 symfony [info] {sfPatternRouting} 匹配路由 "homepage" (/) for / 参数数组 ('module' => 'main', 'action' => 'index',)
3 月 16 日 05:57:42 symfony [err] {sfParseException} 配置文件“D:\wamp\bin\php\symfony\symfony14\lib/config/config/filters.yml”指定类别“flash”缺少类键。
【问题讨论】:
-
@Gaff:能把代码贴在对应的action方法里面吗?
标签: jquery-plugins symfony1 symfony-1.4