[
https://issues.apache.org/struts/browse/WW-2752?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Tamas Ruff updated WW-2752:
---------------------------
Assignee: Adi Baron
Sorry, my fault. The documentation
http://struts.apache.org/2.x/docs/freemarker-result.html suggested to me that
if the location starts with / then it looks at the path relative to the web
root folder, otherwise the classpath. But this is not the case. If it starts
with the / then it still looks in the classpath or more exactly, only then
looks in the classpath. My conclusion is to start the location always with the
/. Maybe you update the documentation and add the / character to the location:
a classpath resuorce. eg /com/company/web/views/home.ftl
> Freemarker result for the s:action control tag does not search the classpath
> ----------------------------------------------------------------------------
>
> Key: WW-2752
> URL: https://issues.apache.org/struts/browse/WW-2752
> Project: Struts 2
> Issue Type: Bug
> Components: Core Actions
> Reporter: Tamas Ruff
> Assignee: Adi Baron
>
> On the following link
> http://struts.apache.org/2.x/docs/freemarker-result.html one can see that the
> Freemarker template loaders search the web context (if the path begins with a
> /) or the classpath otherwise for loading the templates. It works nice for
> "normal" actions. But if I configure a freemarker result for an action tag
> (s:action) then if the path specified in the result (in struts.xml) starts
> without / then - according to the error message I got - it tries to find the
> template relative to the page the action tag is embedded into, and does not
> search the classpath.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.