You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by "David G. Friedman" <hu...@ix.netcom.com> on 2003/08/05 16:11:25 UTC

Re: RE: Location of JSPs for TILES

Cameron,

I'm VERY new to struts but I had no problem setting up and using tiles.  Here are some of my tiles definitions which I'm using without any problems. Perhaps my definition can show you something you might be overlooking...  BTW, I'm on Tomcat 4.1.24 on a Linux platform using JDK 1.4.2 on Struts 1.1.

I use it through my action's success forward:
<forward name="success" path=".region" />

Regards,
David

------ start tiles snippets -------
<tiles-definitions>
<definition name=".layoutHawaiiSite" path="/WEB-INF/layouts/hawaiifun.jsp">
  <put name="title"  value="HawaiiSite" />
  <put name="header-logo" value="/WEB-INF/layouts/header-logo.jsp" />
  <put name="header-map" value="/WEB-INF/layouts/header-map.jsp" />
  <put name="navigation-left" value="/WEB-INF/layouts/navigation-left.jsp" />
  <put name="center-content" value="/WEB-INF/layouts/empty.jsp" />
</definition>

<definition name=".region" extends=".layoutHawaiiSite">
  <put name="center-content" value="/WEB-INF/layouts/region.jsp"/>
</definition>
------ end tiles snippets -------

-------Original Message-------
From: Cameron Hickey <ca...@panoramatos.com>
Sent: 08/05/03 05:02 PM
To: 'Struts Users Mailing List' <st...@jakarta.apache.org>
Subject: RE: Location of JSPs for TILES

> 
> Is there anyone who knows the rules for using TILES?

I moved the files from /WEB-INF/jsp/proptype to /WEB-INF/tiles/proptype
but this does not solve the problem.

Must all files for a given Tiles definition be located in the same
folder?  I am extending one layout where the base file is located in
/WEB-INF/jsp and the added file is located in /WEB-INF/jsp/proptype

Should this be causing any problems?  Are there an FAQs or other
resources besides the Javadocs for Tiles where I might be able to learn
of its limitations?  Is there something wrong with my design pattern
which others are not employing, which is why my problem seems so
isolated?

Thanks for any more help

Cameron

-----Original Message-----
From: Jones, Marty B. [mailto:marty_jones@dailyaccess.com] 
Sent: Tuesday, August 05, 2003 7:38 PM
To: Struts Users Mailing List
Subject: RE: Location of JSPs for TILES

I am not sure about Tomcat.  I just know that most jsp containers
compile
the source jsp files to servlets within the /WEB-INF/jsp folder so it
probably isnt the best place to put your source files.

-----Original Message-----
From: Cameron Hickey [mailto:cam@panoramatos.com]
Sent: Tuesday, August 05, 2003 11:37 AM
To: 'Struts Users Mailing List'
Subject: RE: Location of JSPs for TILES


Thanks for the response Marty,

I am using Tomcat 4.1.24, and have no problem generally putting these
files into the /jsp folder, its only when I put them into the /jsp/prop
folder that there are problems.

Where can I find out what the rules are for folders to hold JSPs for
either struts, or tiles?  Does Tomcat implement this reserved folder
concept for WEB-INF/jsp ?

Thanks
 
Cameron


-----Original Message-----
From: Jones, Marty B. [mailto:marty_jones@dailyaccess.com] 
Sent: Tuesday, August 05, 2003 7:25 PM
To: Struts Users Mailing List
Subject: RE: Location of JSPs for TILES

I think that the /jsp folder that you are specifying is a reserved
folder
for some jsp containers.  We use /WEB-INF/pages/...

Hope this helps.

-----Original Message-----
From: Cameron Hickey [mailto:cam@panoramatos.com]
Sent: Tuesday, August 05, 2003 11:23 AM
To: struts-user@jakarta.apache.org
Subject: Location of JSPs for TILES


I am having some problems getting TILES to work properly when I put my
JSPs into folders.  The error I get is:

Unable to compile class for JSP An error occurred at line: -1 in the jsp
file: null

Which I assume means that it cannot find the JSP file I have specified
in my tiles-defs.xml.  

If I have my files here:

        /WEB-INF/jsp/proptypelist.jsp

and this in the tiles-defs.xml

  <definition name="PropertyType.list" extends=".list">
        <put name="title"  value="List of Property Types" />
        <put name="body"   value="/WEB-INF/jsp/proptypelist.jsp" />
  </definition>

Then everything works fine.

BUT, if I put the same file a level deeper:

        /WEB-INF/jsp/prop/proptypelist.jsp

with def:

   	<definition name="PropertyType.list" extends=".list">
        <put name="title"  value="List of Property Types" />
        <put name="body"   value="/WEB-INF/jsp/prop/proptypelist.jsp" />
   	</definition>

then I get the error.

Any idea why this would be happening?

Are there limits to how deep or where the templates should be located
for use with TILES?  Is there a way to configure this?

Thanks for any assistance

Cameron Hickey


---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org

---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org

---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org

> 

---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org