aspose file tools*
The moose likes Struts and the fly likes How to Extend Tiles Definition in other pages in Struts 1.x Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "How to Extend Tiles Definition in other pages in Struts 1.x" Watch "How to Extend Tiles Definition in other pages in Struts 1.x" New topic
Author

How to Extend Tiles Definition in other pages in Struts 1.x

Shailesh Kumar Saxena
Greenhorn

Joined: Dec 15, 2012
Posts: 25



Hi Friends...

I am new in Struts framework. I am using Struts 1.3.8.

I am using Struts tiles 1 succesfully, however I have come across a problem when trying to nest tiles.

I currently have a layout like so:
---------------------
Header
---------------------
Content
--------------------
Footer
-------------------

I wish to have another template like this, for use in quite a few user pages:
So I wish to extend the first layout for the user layout. In the tiles definiton I am using:

<definition name=".basic.layout" path="/WEB-INF/jsps/basicLayout.jsp">
....

<definition name=".user.layout" extends=".basic.layout">
<put name="content" value="/WEB-INF/jsps/user/layout.jsp"/>
....

<definition name=".user.page" extends=".user.layout">
<put name="userContent" value="/WEB-INF/jsps/user/page.jsp"/>
....

In user/layout.jsp I attempt to show the tile usually, using <tiles:get name="userContent"/>.

And the problem is The requested resource (/WEB-INF/jsps/user/userContent) is not available

Please provide your valuable suggestions.

Thank you to all of you.


Shailesh Saxena,
Pilibhit, U.P. INDIA
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: How to Extend Tiles Definition in other pages in Struts 1.x