Seam 2.1 问题:失去主题
我正在使用 Seam 开发一个 Web 应用程序,但主题突然停止工作。 我已经恢复了最新的更改,但并没有解决问题。 我什至重新安装了 JBoss (5.1) 服务器,但也没有解决问题。
我在日志中没有看到错误,只是没有显示 css 主题(尽管它在服务器中),控制台中也没有 css 错误。
有人知道解决这个问题的方法吗?
I'm developing a web application with Seam but suddenly the theme has stopped working. I've reverted the latest changes and it doesn't solve it. I've even reinstalled the JBoss (5.1) server but it doesn't fix it either.
I see no error in the logs, just the css theme is not being shown (although it's there in the server), no css errors in the console either.
Does somebody know a way to solve this?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
好吧,一位同事在 Richfaces 的错误报告中找到了解决方案:
https://jira。 jboss.org/jira/browse/RF-2316
重定向到 Seam 的几个 JIRA 报告:
https://jira.jboss.org/jira/browse/JBSEAM-1009
https://jira.jboss.org/jira/browse/JBSEAM-2186
是一个令人讨厌的错误,但有一个解决方法:
也就是说,我希望它能为下一个掉进这个坑的人节省时间。
Ok, one workmate found the solution in a bug report for Richfaces:
https://jira.jboss.org/jira/browse/RF-2316
that redirected to a couple of JIRA reports for Seam:
https://jira.jboss.org/jira/browse/JBSEAM-1009
https://jira.jboss.org/jira/browse/JBSEAM-2186
Is a nasty bug, but there's a workaround:
So that is, I hope it saves time to the next person that falls in this pit.
首先想到的是,css 文件的路径不正确,或者该文件可能不公开。
如果您的模板 xhtml 文件包含对 css 的固定路径引用,并且您最近更改了应用程序上下文,则它可能会查找到错误的位置。 (例如,应用程序曾经位于 http://127.0.0.1/peretool/ 中,现在位于在 http://127.0.0.1/pere/ 或 http://127.0.0.1/)。
否则,请检查 web.xml 中是否有任何可能阻止您的 css 的 servlet。 最好的检查方法是直接在浏览器中输入 css 文件 url,看看会发生什么。
下载 Firebug for Firefox网络模块将帮助你追踪它试图从哪里获取CSS。
First thought, the path to the css file is incorrect, or maybe the file isn't publicly available.
If your template xhtml file contains a fixed path reference to the css, and you recently changed the application context, it might be looking in the wrong place. (for example, app used to be in http://127.0.0.1/peretool/ and now its located in http://127.0.0.1/pere/ or http://127.0.0.1/).
Otherwise, check web.xml for any servlets that might be blocking your css. Best way to check is typing the css file url into your browser directly and see what happens.
Download Firebug for Firefox, the network module will help you track down where its trying to get the css from.