Parent theme could not be found when customize template dir
-----------------------------------------------------------
Key: WW-2920
URL: https://issues.apache.org/struts/browse/WW-2920
Project: Struts 2
Issue Type: Bug
Components: Core Actions
Affects Versions: 2.1.2
Environment: Tomcat 6.0.18
Reporter: Tom Nguyen
When customizing freemarker template folder to any different folder than
"template"
<constant name="struts.ui.templateDir" value="WEB-INF/template" /> in
struts.xml or
struts.ui.templateDir=WEB-INF/template in struts.properties
struts.ui.theme=xhtml
When browse to a jsp or action page, errors happen because it could not found
the template file in parent dir. for example the actionerror.ftl or
div-close.ftl in simple theme (template/simple dir), but struts2 try to look up
this file in xhtml(template/xhtml dir)
2008-12-17 18:09:56,440 ERROR (org.apache.struts2.components.UIBean:28) - error
when rendering
java.io.FileNotFoundException: Template /WEB-INF/template/xhtml/actionerror.ftl
not found.
at freemarker.template.Configuration.getTemplate(Configuration.java:489)
at freemarker.template.Configuration.getTemplate(Configuration.java:452)
at
org.apache.struts2.components.template.FreemarkerTemplateEngine.renderTemplate(Freemarker
TemplateEngine.java:121)
at org.apache.struts2.components.UIBean.mergeTemplate(UIBean.java:558)
at org.apache.struts2.components.UIBean.end(UIBean.java:512)
at
org.apache.struts2.views.jsp.ComponentTagSupport.doEndTag(ComponentTagSupport.java:42)
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.