Reputation: 132
Tiles configuration
<definition name="defaultLayout" template="/{1}/{2}/common/{4}/layouts/layout.jsp">
<put-attribute name="header" value="header.jsp" />
<put-attribute name="body" value="" />
<put-attribute name="footer" value="/{1}/{2}/common/s/footer.jsp" />
</definition>
<!-- Default Layout Defination over -->
<definition name="*/*/*/*/*/index" extends="defaultLayout">
<put-attribute name="body" value="/{1}/{2}/common/s/index.jsp" />
Problem is my defaultLayout
definition was not replace with define wildcart in child definition.
When I was hit URL from my browser like http://localhost:8080/etisalat/wap/common/b/index.wfv
then
Error is
HTTP Status 404 - /{1}/{2}/common/{4}/layouts/layout.jsp
type Status report
message /{1}/{2}/common/{4}/layouts/layout.jsp
description The requested resource (/{1}/{2}/common/{4}/layouts/layout.jsp) is not available.
Apache Tomcat/6.0.32
Upvotes: 0
Views: 38
Reputation: 1150
The wildcard placeholders are not passed on to the inherited definition.
You would need to
<definition name="defaultLayout.*.*.*" template="/{1}/{2}/common/{3}/layouts/layout.jsp">
<put-attribute name="header" value="header.jsp" />
<put-attribute name="body" value="" />
<put-attribute name="footer" value="/{1}/{2}/common/s/footer.jsp" />
</definition>
<definition name="*/*/*/*/*/index" extends="defaultLayout.{1}.{2}.{4}">
<put-attribute name="body" value="/{1}/{2}/common/s/index.jsp" />
...
Upvotes: 1