You are viewing a plain text version of this content. The canonical link for it is here.
Posted to watchdog-dev@jakarta.apache.org by rl...@apache.org on 2002/07/18 03:23:34 UTC
cvs commit: jakarta-watchdog-4.0/src/tools/org/apache/watchdog/jspxml jsp2XML.java
rlubke 2002/07/17 18:23:34
Modified: src/tools/org/apache/watchdog/jspxml jsp2XML.java
Log:
- modified previous change that prefixed all relative taglib URI's with urn:jsptld
so that only uri's that end in .jar or are direct references to TLDs in the WEB-INF
directory will be prefixed.
Revision Changes Path
1.3 +14 -5 jakarta-watchdog-4.0/src/tools/org/apache/watchdog/jspxml/jsp2XML.java
Index: jsp2XML.java
===================================================================
RCS file: /home/cvs/jakarta-watchdog-4.0/src/tools/org/apache/watchdog/jspxml/jsp2XML.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- jsp2XML.java 27 Jun 2002 16:07:36 -0000 1.2
+++ jsp2XML.java 18 Jul 2002 01:23:34 -0000 1.3
@@ -154,8 +154,17 @@
if (!tag_prefix.containsKey(prefix)) {
tag_prefix.put(prefix , prefix);
- if (uri.charAt(0) == '/') {
- // URI is relaitve
+ // URI is relaitve and directly references a TLD
+ // or a JAR file, then the URI must be prefixed by
+ // 'urn:jsptld:
+ // This is an ugly hack for the conversion, but
+ // given that an uri mapping in either a DD or
+ // TLD could end with the prefix of .tld, there
+ // is no easy way from the conversion point of
+ // view to determine the intention of the JSP.
+ // Will assume if the URI contains WEB-INF,
+ // that it is a direct reference.
+ if (uri.endsWith(".jar") || uri.indexOf("WEB-INF") > -1) {
uri = "urn:jsptld:" + uri;
}
//add to the xml NameSpace
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>