Tiles w/o Stuts problem.



I'm trying to implement Tiles ( from Struts 1.3 ) into a web that is
NOT using Struts. I've found and followed instruction on doing this
and the docs I've found don't seem to work. The latest docs I've been
able to find to do this, BTW, are for 1.1.

The problem I'm having is that tiles isn't finding my tiles-defs.xml
file. At least that is what I assume this error means:

javax.servlet.jsp.JspException: Can't get definitions factory from
context.
at
org.apache.struts.tiles.taglib.InsertTag.processDefinitionName(Ljava.lang.String;)Lorg.apache.struts.tiles.taglib.InsertTag
$TagHandler;(Unknown Source)
at
org.apache.struts.tiles.taglib.InsertTag.createTagHandler()Lorg.apache.struts.tiles.taglib.InsertTag
$TagHandler;(Unknown Source)
at org.apache.struts.tiles.taglib.InsertTag.doStartTag()I(Unknown
Source)

How do I configure my app to see the tiles-defs.xml? I've tried each
of the following entries (both the context-param and the servlet
entries) in my web.xml file (see code snippet below).

Note: Using the servlet definition ( Tiles Servlet ) failed because
TilesServlet doesn't seem to be exist since Struts 1.1.

Can anyone please point me in the correct direction?
TIA

<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE web-app
PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
"http://java.sun.com/dtd/web-app_2_3.dtd"> <web-app>
<context-param> <param-name>
org.apache.tiles.impl.BasicTilesContainer.DEFINITIONS_CONFIG </
param-name> <param-value> /WEB-INF/tiles-defs.xml,/org/apache/
tiles/classpath-defs.xml </param-value> </context-param>
<!-- Uncommented and tried - did not work - TilesServlet doesn't
exist in any of the Struts jars --> <!-- servlet> <servlet-
name>Tiles Servlet</servlet-name> <servlet-
class>org.apache.struts.tiles.TilesServlet</servlet-class>
<init-param> <param-name>definitions-config</param-
name> <param-value>/WEB-INF/tiles-defs.xml</param-
value> </init-param> <init-param> <param-
name>definitions-parser-validate</param-name> <param-
value>true</param-value> </init-param> <load-on-
startup>2</load-on-startup> </servlet --> </web-
app>
.



Relevant Pages

  • Struts Tiles Error
    ... Struts 1.3 and Tiles 2.1.3. ...
    (comp.lang.java.programmer)
  • Re: httprequest cant find servlet
    ... Did you deploy the servlet to Glassfish? ... under the hood by Struts for you. ... for pedagogical purposes): http://localhost:8001/foo/? ...
    (comp.lang.java.programmer)
  • PageContext issue - getting "Cannot forward after response has been committed"
    ... I am trying to utilize Tiles in my struts application but am having ... in my actual JSP when I try to use Tiles I ... I know that my response has not been commited. ...
    (comp.lang.java.programmer)
  • Re: Struts + Velocity + GWT
    ... In my case I would get some kind of integration with Struts and Dojo, ... request to load the tiles and bind the strust buttons with Asyncronous ...
    (comp.lang.java.programmer)
  • Re: httprequest cant find servlet
    ... Did you deploy the servlet to a web container, ... under the hood by Struts for you. ... I dont use struts i think? ...
    (comp.lang.java.programmer)