This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes JSF and the fly likes No tag library could be found with this URI Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » JSF
Bookmark "No tag library could be found with this URI" Watch "No tag library could be found with this URI" New topic
Author

No tag library could be found with this URI

Indu Sekhar
Greenhorn

Joined: Dec 08, 2009
Posts: 2
Hello Friends,
I am using JSF for my project and I am still getting familiar with it. Meanwhile I am getting the following error in one of the examples [I am trying.
I have searched for solutions in google but surprisingly there were only questions but no answers.
I would really appreciate if someone takes time and shares the solution so not only me but many others would benefit from it.
Environment details:
Version: 3.4.2
Server: BEA Weblogic Server v10.0
Java version : JDK150_11
Maven : 2.0.7



Here is the Error:

javax.faces.FacesException: weblogic.servlet.jsp.CompilationException: Failed to compile JSP /pages/inputname.jsp
inputname.jsp:3: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://java.sun.com/jsf/core" prefix="f"%>
^----^

at org.apache.myfaces.context.servlet.ServletExternalContextImpl.dispatch(ServletExternalContextImpl.java:432)
at org.apache.myfaces.application.jsp.JspViewHandlerImpl.renderView(JspViewHandlerImpl.java:255)
at org.apache.myfaces.lifecycle.RenderResponseExecutor.execute(RenderResponseExecutor.java:41)
at org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:146)
at javax.faces.webapp.FacesServlet.service(FacesServlet.java:147)
Truncated. see log file for complete stacktrace
javax.servlet.ServletException: weblogic.servlet.jsp.CompilationException: Failed to compile JSP /pages/inputname.jsp

These are the following Jars I am using:

myFaces-api-1.1.7.jar
jstl-1.2.jar
myfaces-impl-1.1.7.jar
servlet-api-2.4.jar
and some commons...*.jar...

I have tried few combinations of the version of the above jars too.
I am not using a weblogic.xml file.


The web.xml file is:

?xml version="1.0" encoding="UTF-8"?>
<web-app version="2.5" xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_5.xsd" id="WebApp_ID">


<display-name>
evalAlgorithm</display-name>

<context-param>
<param-name>javax.faces.STATE_SAVING_METHOD</param-name>
<param-value>server</param-value>
</context-param>

<context-param>
<param-name>javax.faces.CONFIG_FILES</param-name>
<param-value>/WEB-INF/faces-config.xml</param-value>
</context-param>
<listener>
<listener-class>
org.apache.myfaces.webapp.StartupServletContextListener
</listener-class>
</listener>

<!-- Faces Servlet -->
<servlet>
<servlet-name>Faces Servlet</servlet-name>
<servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
<load-on-startup>1</load-on-startup>
</servlet>

<!-- Faces Servlet Mapping -->
<servlet-mapping>
<servlet-name>Faces Servlet</servlet-name>
<url-pattern>*.jsf</url-pattern>
</servlet-mapping>

<welcome-file-list>
<welcome-file>index.html</welcome-file>
<welcome-file>index.htm</welcome-file>
<welcome-file>index.jsp</welcome-file>
<welcome-file>default.html</welcome-file>
<welcome-file>default.htm</welcome-file>
<welcome-file>default.jsp</welcome-file>
</welcome-file-list>
</web-app>


I sincerely appreciate someone sharing their expertise on this.

Thanks,
Indu.

Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 15950
    
  19

Welcome to the JavaRanch, Indu. Your posting was colorful, but we have a "code" button on the editor that will wrap tags around your code samples and keep them from getting reformatted.

The URI in question should have been resolved in the faces-api.jar. I don't think the MyFaces-api.jar is the same thing, since the JSF faces-api is part of the Sun specs, not a per-vendor thing. So you may need to add that jar to your WAR's WEB-INF/lib collection.

Customer surveys are for companies who didn't pay proper attention to begin with.
Indu Sekhar
Greenhorn

Joined: Dec 08, 2009
Posts: 2
Tim,
Thank you for the response.
I will keep the code button in mind for the new posts I would be doing.

You solution made me think and try few things.
Meanwhile I copied a sample project from my friend and it works great. The sample project is using the myfaces-api.jar and myfaces-impl.jar
I see everything is same with respect to my project and sample project and am I still getting the error. So I am not sure why mine isn't working. I have pretty much all the jars he is having...

Thanks,
Indu.
 
wood burning stoves
 
subject: No tag library could be found with this URI
 
Similar Threads
Error JSF 2.1: java.io.FileNotFoundException:*/*.xhtml Not Found in ExternalContext
Unable to read TLD "META-INF/jsf_core.tld from jsf-impl-2.0.jar when "Integrating JSF with Struts
how to initiate hashtable and linklist
Problem with RichFaces
myFaces Component and JSF netbeans