- This topic has 8 replies, 5 voices, and was last updated 21 years, 4 months ago by support-michael.
-
AuthorPosts
-
bsiggelkowMemberI apologize if this has already been reported. I have a JSP that is using an absolute URI instead of referring to taglib references in the web.xml — however, MyEclipse doesn’t understand this and reports the following error in the JSP Editor:
bad relative URL in web.xml: taglib-location=http://java.sun.com/jstl/core
If I explicitly declare the taglib in the web.xml the error goes away.
Scott AndersonParticipantActually it was reported recently because our 2.6.2 release is very specification-compliant and this has caused some confusion. The issue is really caused because your usage of taglibs isn’t really in conformance with the JSP spec. This thread (https://www.genuitec.com/forums/topic/upgrade-to-myeclipse-2-6-2-not-an-improvement-closed/) runs it all down for you.
–Scott
MyEclipse Support
bsiggelkowMemberHmm … I think my usage does conform to the JSP 1.2 specification [JSP.7.3.4] . Does MyEclipse support this specification?
JSP.7.3.4 Implicit Map entries from TLDs
The taglib map described in web.xml is extended with new entries extracted
from TLD files in the Web Application. The new entries are computed as follows:
• Each TLD file is examined. If it has a <uri> element, then a new <taglib> element
is created, with a <taglib-uri> subelement whose value is that of the <uri>
elemement, and with a <taglib-location> subelement that refers to the TLD file.
• If the created <taglib> element has a different <taglib-uri> to any in the taglib
map, it is added.
This mechanism provides an automatic URI to TLD mapping as well as
supporting multiple TLDs within a packaged JAR. Note that this functionality
does not require explicitly naming the location of the TLD file, which would
require a mechanism like the jar: protocol.
Note also that the mechanism does not add duplicated entries.
support-michaelKeymasterIs the taglib that your are referencing packaged as a JAR or is it the TLD exposed under the WEB-INF dir? I am assuming it is a packaged TLD since it has been my understanding that is the purpose for the implicit mechanism you cite from the spec.
Michael
MyEclipse Support
No OperationMemberThe implicit loading works for me.
Guess the problem is the URI vs URL.
using an absolute URI
As far as I understand, URIs are relative, everywhere in JSPs.
absolute URI
does not exist.
=>
[spec]
JSP.2.2.1 Relative URL Specifications
Elements may use relative URL specifications, called “URI paths” in the Servlet 2.3
specification.
[/spec]NOP
bsiggelkowMemberYes, the TLD is packaged in a jar.
@support wrote:Is the taglib that your are referencing packaged as a JAR or is it the TLD exposed under the WEB-INF dir? I am assuming it is a packaged TLD since it has been my understanding that is the purpose for the implicit mechanism you cite from the spec.
Michael
MyEclipse Support
support-michaelKeymasterThanks for the feedback. We are researching this now.
Michael
MyEclipse Support
SolNetMemberI am also having this problem.
I have the JSTL package as “standard.jar” located in WEB-INF/lib.
Within this jar is c.tld (the normal tld for the “core” of JSTL) located in the meta-inf directory of the standard.jar file.the JSP editor complains that the
“bad relative URL in web.xml: taglib-location = http://java.sun.com/jstl/core”
But If I deploy the app – it works – Tomcat works correctly.If I put a copy of the c.tld in the WEB-INF directory and change the @taglib uri=”…” to reference this file – the editor likes it, but it confuses tomcat – and is not really valid to the spec.
the otherthing is, the @taglib tag is meant to support URI and “TAGDIR” – but the JSP editor does not understand this attribute of taglib.
let me know if you need more info
Nick
support-michaelKeymasterWe have a fix available that address this problems discussed in this thread. We expect to release it as part of maintenance or minor release within the next 2 weeks.
Michael
MyEclipse Support -
AuthorPosts