Skip to main content

The ELResolvers for JSF were not registered in the JSP container

Please note these java.net forums are being decommissioned and use the new and improved forums at https://community.oracle.com/community/java.
3 replies [Last post]
Stoney
Offline
Joined: 2006-02-17

Hello,
when starting up a new glassfish installation (mac os) with a standard domain, the server.log gives me the message
"The ELResolvers for JSF were not registered in the JSP container".
That seems to be the cause no message bundles are loaded. What could I do to solve that issue?
Regards,
Stoney

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
Stoney
Offline
Joined: 2006-02-17

Hallo,

on linux I could load the application with tomcat without any problems. Unter tomcat 7 the same message appeared "The ELResolvers for JSF were not registered in the JSP container" but the message bundle could be loaded correctly (i.e. with the "translation" from the properties file). The application is like a hello world application:

Could anybody help me on that one?

index.xhtml

<?xml version="1.0" encoding="UTF-8"?>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:f="http://java.sun.com/jsf/core"
xmlns:h="http://java.sun.com/jsf/html">
<h:head>
<title>#{msgs.title}</title>
</h:head>
<h:body>
<h3>#{msgs.heading}</h3>
</h:body>

messages.properties

title=Zahlenquiz
header=This is the heading

faces-config.xml

<?xml version="1.0"?>

<faces-config xmlns="http://java.sun.com/xml/ns/javaee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
http://java.sun.com/xml/ns/javaee/web-facesconfig_2_0.xsd"
version="2.0">
<application>
<locale-config>
<default-locale>de</default-locale>
<supported-locale>en</supported-locale>
</locale-config>
<resource-bundle>
<base-name>resources.messages</base-name>
<var>msgs</var>
</resource-bundle>
</application>

web.xml

<?xml version="1.0" encoding="UTF-8"?>

<web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="http://java.sun.com/xml/ns/javaee"
xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
version="2.5">
<servlet>
<servlet-name>Faces Servlet</servlet-name>
<servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
</servlet>
<servlet-mapping>
<servlet-name>Faces Servlet</servlet-name>
<url-pattern>*.jsf</url-pattern>
</servlet-mapping>
<welcome-file-list>
<welcome-file>index.xhtml</welcome-file>
</welcome-file-list>
<context-param>
<param-name>javax.faces.PROJECT_STAGE</param-name>
<param-value>Development</param-value>
</context-param>

Stoney
Offline
Joined: 2006-02-17

change the configuration of the project to be a JavaServer 2.0 configuration and it will work :|

Stoney
Offline
Joined: 2006-02-17

change the configuration of the project to be a JavaServer 2.0 configuration and it will work :|