I haven't seen a final answer to this, but in all cases where Struts is doing a validating parse of an XML document (including validator, which is actually commons-validator and not core Struts code), the DTDs are registered so that if you have the correct public ID, the code will read them from the classpath instead of from the internet URL.

The correct public IDs should be embedded in the versions of the DTDs in the distribution. Most often when people have problems because the validator can't find the DTD, it is because they haven't got the right DOCTYPE declaration in their XML.

Joe


At 4:41 PM -0800 1/19/05, Tim wrote:
David,
I've tried that option before of course, and I re-did it again just to make sure and still not solving it.
I've used the absolute path F:/Projects...
and changed the / with \\
and all did not work.


----- Original Message ----- From: "David G. Friedman" <[EMAIL PROTECTED]>
To: "Struts Users Mailing List" <user@struts.apache.org>
Sent: Wednesday, January 19, 2005 4:21 PM
Subject: RE: Referencing the Local DTD rather than the http:// one

Tim,

I thought you were supposed to take out the "-//Apache ...." part when using
a SYSTEM local url AND that using dot-dot-slash "../" notation in a TLD was
a bad idea.  Have you already tried it with those two changes at the same
time?

Regards,
-David

-----Original Message-----
From: Tim [mailto:[EMAIL PROTECTED]
Sent: Wednesday, January 19, 2005 6:53 PM
To: Struts Tiles
Subject: Referencing the Local DTD rather than the http:// one


Hi all, This might look trivial, but took enough time and effort searching for the answer

I am using struts tiles, and build the entire application without problems
and works great.
until I changed the reference to the dtd file in the tiles-definition.xml
file from the original:

<!DOCTYPE tiles-definitions
  PUBLIC "-//Apache Software Foundation//DTD Tiles Configurations 1.1//EN"
 "http://jakarta.apache.org/struts/dtds/tiles-config_1_1.dtd";>


to <!DOCTYPE tiles-definitions SYSTEM "-//Apache Software Foundation//DTD Tiles Configurations 1.1//EN" "../dtds/tiles-config_1_1.dtd">

where my WEB-INF directory contains
WEB-INF/tiles/tiles-definition.xml
WEB-INF/dtds/tiles-config_1_1.dtd

All I need is to reference to the local dtd rather than the internet one.

When I run the application I get the exception (as you can tell. I am using
Oracle JDeveloper 10g)
:
javax.servlet.jsp.JspException: Can't get definitions factory from context.

at
org.apache.struts.taglib.tiles.InsertTag.processDefinitionName(InsertTag.jav
a:583)

at
org.apache.struts.taglib.tiles.InsertTag.createTagHandler(InsertTag.java:487
)

at org.apache.struts.taglib.tiles.InsertTag.doStartTag(InsertTag.java:451)

at _res._resWelcome._jspService(resWelcome.jsp:8)

[/res/resWelcome.jsp]

at oracle.jsp.runtime.HttpJsp.service(HttpJsp.java:139)

at oracle.jsp.runtimev2.JspPageTable.service(JspPageTable.java:349)

at oracle.jsp.runtimev2.JspServlet.internalService(JspServlet.java:509)

at oracle.jsp.runtimev2.JspServlet.service(JspServlet.java:413)

at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)

at com.evermind[Oracle Application Server Containers for J2EE 10g
(9.0.4.0.0)].server.http.ResourceFilterChain.doFilter(ResourceFilterChain.ja
va:65)

at oracle.security.jazn.oc4j.JAZNFilter.doFilter(Unknown Source)

at com.evermind[Oracle Application Server Containers for J2EE 10g
(9.0.4.0.0)].server.http.ServletRequestDispatcher.invoke(ServletRequestDispa
tcher.java:604)

at com.evermind[Oracle Application Server Containers for J2EE 10g
(9.0.4.0.0)].server.http.ServletRequestDispatcher.forwardInternal(ServletReq
uestDispatcher.java:317)

at com.evermind[Oracle Application Server Containers for J2EE 10g
(9.0.4.0.0)].server.http.HttpRequestHandler.processRequest(HttpRequestHandle
r.java:790)

at com.evermind[Oracle Application Server Containers for J2EE 10g
(9.0.4.0.0)].server.http.HttpRequestHandler.run(HttpRequestHandler.java:270)

at com.evermind[Oracle Application Server Containers for J2EE 10g
(9.0.4.0.0)].server.http.HttpRequestHandler.run(HttpRequestHandler.java:112)

at com.evermind[Oracle Application Server Containers for J2EE 10g
(9.0.4.0.0)].util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableRe
sourcePooledExecutor.java:192)

at java.lang.Thread.run(Thread.java:534)


--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


--
Joe Germuska [EMAIL PROTECTED] http://blog.germuska.com "Narrow minds are weapons made for mass destruction" -The Ex


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to