This discussion is archived
2 Replies Latest reply: Aug 2, 2013 5:07 AM by MarcusKrassmann RSS

Weblogic Error -  Spring tags

929482 Newbie
Currently Being Moderated
I'm getting an error when i try to access a page with spring taglibs.
During the deploy there are not any error.

Error:

personAdd.jsp:2:5: No tag library could be found with this URI. Possible causes could be that the URI is incorrect, or that there were errors during parsing of the .tld file.
<%@ taglib uri="http://www.springframework.org/tags/form" prefix="form" %>


Weblogic: 12c
Sts: 2.9.1

Has anyone had this error ??


i already read some solutions in foruns like add this at weblogic.xml but doesn't work:

<wls:container-descriptor>
          <wls:prefer-web-inf-classes>true</wls:prefer-web-inf-classes>
     </wls:container-descriptor>
<wls:container-descriptor>
<wls:index-directory-enabled>true</wls:index-directory-enabled>
</wls:container-descriptor>
  • 1. Re: Weblogic Error -  Spring tags
    murali veligeti - oracle Expert
    Currently Being Moderated
    Hi,

    1.Download the Spring dependency jar
    2.Place it to the lib folder path is /WEB-INF/lib/spring.jar 3.Then open the web.xml and the sample code is:

    <taglib>
    <taglib-uri>/WEB-INF/spring.tld</taglib-uri>
    <taglib-location>/WEB-INF/spring.tld</taglib-location>
    </taglib>

    4.Then the taglib is indicated where the jar file locates in ur system.

    <%@ taglib prefix="spring" uri="/WEB-INF/spring.tld" %>



    Thanks & Regards,
    Murali.
    ===========
  • 2. Re: Weblogic Error -  Spring tags
    MarcusKrassmann Newbie
    Currently Being Moderated

    I encounter the same problem:


    I and my colleagues have the same issue. Our taglibs are not found by Weblogic 12c (12.1.1) if we use STS 3.2 and 3.3 to deploy our multi-module web application (using Java 7). If for deployment we use an order Eclipse JEE release, IntelliJ IDEA or the admin console, everything runs fine. The only taglib that seems to be found is the standard JSTL taglib. For all others, we get an error like this:

     

    javax.servlet.ServletException: weblogic.servlet.jsp.CompilationException: Failed to compile JSP /WEB-INF/pages/index.jsp

    index.jsp:2:22: Error in "C:\Development\tmp\portal-intern\web\src\main\webapp\WEB-INF\pages\include.jsp" at line 5: No tag library could be found with this URI. Possible causes could be that the URI is incorrect, or that there were errors during parsing of the .tld file.

    --%><%@ include file="/WEB-INF/pages/include.jsp"%><%--

                         ^--------------------------^

    index.jsp:2:22: Error in "C:\Development\tmp\portal-intern\web\src\main\webapp\WEB-INF\pages\include.jsp" at line 6: No tag library could be found with this URI. Possible causes could be that the URI is incorrect, or that there were errors during parsing of the .tld file.

    --%><%@ include file="/WEB-INF/pages/include.jsp"%><%--

                         ^--------------------------^

    index.jsp:2:22: Error in "C:\Development\tmp\portal-intern\web\src\main\webapp\WEB-INF\pages\include.jsp" at line 7: No tag library could be found with this URI. Possible causes could be that the URI is incorrect, or that there were errors during parsing of the .tld file.

    --%><%@ include file="/WEB-INF/pages/include.jsp"%><%--

                         ^--------------------------^

    index.jsp:2:22: Error in "C:\Development\tmp\portal-intern\web\src\main\webapp\WEB-INF\pages\include.jsp" at line 8: No tag library could be found with this URI. Possible causes could be that the URI is incorrect, or that there were errors during parsing of the .tld file.

    --%><%@ include file="/WEB-INF/pages/include.jsp"%><%--

                         ^--------------------------^

    index.jsp:2:22: Error in "C:\Development\tmp\portal-intern\web\src\main\webapp\WEB-INF\pages\include.jsp" at line 9: No tag library could be found with this URI. Possible causes could be that the URI is incorrect, or that there were errors during parsing of the .tld file.

    --%><%@ include file="/WEB-INF/pages/include.jsp"%><%--

                         ^--------------------------^

      at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:298)

      at weblogic.servlet.internal.ServletStubImpl.onAddToMapException(ServletStubImpl.java:453)

      at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:364)

      at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:221)

      at weblogic.servlet.internal.RequestDispatcherImpl.invokeServlet(RequestDispatcherImpl.java:564)

      at weblogic.servlet.internal.RequestDispatcherImpl.forward(RequestDispatcherImpl.java:263)

    [...]

     

    The lines before #5 are these:

     

    <%-- these are the taglibs used in the prototype, these are included on each page --%><%--

    --%><%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %><%--

    --%><%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %><%--

    --%><%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %><%--

     

    And after that, we have our MVC framework and the display taglib with entries like this:

     

    --%><%@ taglib prefix="d" uri="http://displaytag.sf.net" %><%--

     

    The comments are not the root cause as they just prevent blank newlines at the beginning of our rendered HTML.

     

    What does work is the STS together with Weblogic 10.3 and 11g. It seems to be a specific problem with the combination of Oracle Weblogic 12c and its support within STS / Eclipse. I already did an update to OEPE 5.3.0 and a fresh workspace and project checkout, but the result is still the same.

     

    If you need more detailled information, I will happily provide them.

     

    Kind regards,

    Marcus

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points