- This topic has 26 replies, 9 voices, and was last updated 20 years, 7 months ago by
Riyad Kalla.
-
AuthorPosts
-
Scott AndersonParticipantEmanuel,
Eclipse3 release and 2.8beta1 again
I’m sure that was just a typo, but please make it 3.8beta1, not 2.8beta1. 🙂
tuboobooMemberit was a typo indeed – sorry for confusing you. I retried and can still reproduce the issue with Eclipse 3 Final and 3.8beta 1 — this is a real bummer, as the compile error from the first taglib directive disables many editor capabilities, suchas sourcecode completion etc.
Can you guys let me know if this is true for a few people only, or whether it is a general problem that will be fixed soon? I just subscribed, and hope you can fix this one… right now its not possible…
Thanks again for the timely replies
Emanuel
Scott AndersonParticipantEmanuel,
Can you guys let me know if this is true for a few people only, or whether it is a general problem that will be fixed soon?
It’s definately not a general issue so it most likely has something to do with your project configuration or installation. Can you check your log file for any stacktraces? The log is located at <workspace>/.metadata/.log. If the log looks clear it’s most likely the way the project is set up. If that’s the case, could you create the smallest possible web project that exhibits the problem, zip the project directory, and email it to us for investigation?
tuboobooMemberinteresting — after browsing the forums some more on the topic, i found a post related to oscache TLD problems
http://www.myeclipseide.com/PNphpBB2+file-viewtopic-t-2644-highlight-taglib+oscache.html
where the fix involved putting an absolute <uri>http://opensymphony.com/oscache</uri> into the oscache.jar’s META_INF/taglib.tld file, and referencing the taglib using
<%@ taglib uri=”http://opensymphony.com/oscache” prefix=”oscache” %>
instead of
<%@ taglib uri=”oscache” prefix=”oscache” %>
That actually solved the problem for me as well. Now the only question remains, are only absolute URI’s currently supported by the MyEclipse JSP editor? (our codebase has them in relative form, and i am kind of reluctant to have them all changed…)
Thanks again for your continued support. A 29$ well spent!
Emanuel
Riyad KallaMemberEmanuel,
I just downloaded OS Cache and installed it into my webapp without problems… the key was that I <long drawn out pause> followed the install.html file that came with it 😀I believe the fundamental difference between OSCache’s JAR and something like Struts’s JAR, is that even though both contain the TLD files for the tags in the JAR, the OSCache TLD does not define a default URI like Struts does. So MyEclipse is not able to resolve the tags in the JAR file. At any rate, the install instructions tell you to copy the TLD file from the <oscache dir>\etc directory into your classes dir… I don’t agree with this, so I put it in my WEB-INF dir, and updated my taglib-location in my web.xml and walla, everything works fine.
I have the same problem.
I’m use Ecelipse 3 and MyEclipse3.8 beta 1.All of my JSPs use the following tag:
<%@ taglib uri=”/invgui” prefix=”gui” %>
… and I got the same error.Does someone know when this bug will be fixed?
Riyad KallaMemberfisrael,
How do you know its a bug? What taglib entries do you ahve in your web.xml file? Where is the TLD file located? If you open it up, does it define a URI for the taglib? Where are the classes for this taglib?Hello,
thanks for your response. The source codes of my current project has been already developed with
JBuilder and the web project runs very well on different webapplication servers like WebSphere
and Jetty.
A few days ago I decide to use Eclipse 3 with your latest plugin for the further development
on this web project. So I have created a new web project in eclipse with the old well tested sources.
JBuilder had no problem with my taglib. Obviously Eclipse or the MyEclipse Plugin doesn’t search in
the web.xml file on development time to search for the required taglib entry or are not able to handle
simple relative URIs. That could be the bug – I think.In my web.xml file there exist an entry:
<taglib>
<taglib-uri>/invgui</taglib-uri>
<taglib-location>/tlds/invgui.tld</taglib-location>
</taglib>Physically the TLD file is located as so as in the web.xml entry described –
relative to the WebRoot seperatly in the dir tlds.There the invgui.tld file start with the following code:
<?xml version=”1.0″ encoding=”ISO-8859-1″ ?>
<!DOCTYPE taglib
PUBLIC “-//Sun Microsystems, Inc.//DTD JSP Tag Library 1.1//EN”
“http://java.sun.com/j2ee/dtds/web-jsptaglibrary_1_1.dtd”><taglib>
<tlibversion>1.0</tlibversion>
<jspversion>1.1</jspversion>
<shortname>RSI GUI default tags</shortname>
<info>yyyy xxxxx Default GUI Tags</info><tag>
<name>vspace</name>
<tagclass>com.yyy.xxx.foc.taglibs.dflt.VerticalSpace</tagclass>
<bodycontent>JSP</bodycontent>
<info>xxx FOC vertical space</info><attribute>
<name>repeat</name>
<required>false</required>
<rtexprvalue>true</rtexprvalue>
</attribute>
</tag>
….There exist more than one tag entries. There tag class file are located
as so as in the invgui.tld file decribed. The sources of the class files
(packages) are part of the project source.As decribed in my JSPs I use the following sequence:
<%@ taglib uri=”/invgui” prefix=”gui” %>
If I deploy the JSPs and the other project code to an ApplicationServer
all runs very well. Only MyEclipse shows me a small red icon near the
JSP sequence and on mouseover a next comes up like: Could not load tld …So I would ask you when the next release will be available, because
I have paid for the MyEclipse 3.8 beta 1 and I think it would be nice
to use the full set of offered features ….Frank
… a text comes up like …
Riyad KallaMemberFrank,
This is not a bug, your taglib is in an illegal location according to web application spec from Sun. Your tld files cannot be under /tlds because they will be publically accessible (since they are a direct child of WebRoot and not under WEB-INF).Here is a quote from the spec:
Tag library descriptor file names must have the extension .tld and must be packaged in the /WEB-INF/ directory or subdirectory
Please see these link:
http://java.sun.com/j2ee/1.4/docs/tutorial/doc/WebApp3.html#wp225219
http://java.sun.com/j2ee/1.4/docs/tutorial/doc/JSPTags6.html#wp90086As far as why JBuilder allows this, I can only guess. They probably thought it was easier for developers, which I suppose it is, but it is dangerous, against spec, and not compliant with other IDEs.
Hello Riyad,
many thanks to you for your support. I have moved the subdir /tlds from WebRoot to WebRoot/WEB-INF
and after a new saving of the JSP pages all errors at my JSP taglib sequence disappeared. 🙂I’m sorry, I have developed the tags in my project 2 years ago and until now I don’t notice
that I have put the tld file into a wrong dir – against the specification. It seems that I had
overlooked a detail in my books.Frank
Riyad KallaMemberFrank,
I’m glad to hear everything is working now, please don’t hestitate to ask if you run into any other problems. -
AuthorPosts