Win a copy of Head First Android this week in the Android forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
  • Tim Cooke
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Liutauras Vilda
  • Jeanne Boyarsky
  • Rob Spoor
  • Bear Bibeault
Saloon Keepers:
  • Jesse Silverman
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Piet Souris
  • Al Hobbs
  • salvin francis

JSF Navigation Issue

Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Dear All Frnds:

I am new to JSF and i have created an EAR application contains JSF/Hibernate
but in my case when i try to access my application's JSP page then it works fine but when i try to open those pages contain jsf taglib they give me an error that this page can not be displayed.

What could be the issue.. the below code works fine as it doesn't contain any JSF Taglib tag in header..

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<%@ page language="java" %>
<%@ page import="java.util.ArrayList"%>
ArrayList errors;
errors = (ArrayList)request.getAttribute("errors");
<meta http-equiv="Content-Language" content="en-us">
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<meta name="GENERATOR" content="IBM WebSphere Studio">
<font face="Arial">
<font face="Arial">
<% if (errors == null) {
out.write("No Errors Found.");
} else {
for (int i=0; i < errors.size(); i++) {
out.write(i + ": " + (String)errors.get(i) + "<br>");

but issue is related to this file

<%@ page language="java" pageEncoding="ISO-8859-1"%>
<%@ taglib uri="" prefix="h" %>
<%@ taglib uri="" prefix="f" %>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

<title>My JSF 'userLogin.' starting page</title>

<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="expires" content="0">
<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
<meta http-equiv="description" content="This is my page">
<link rel="stylesheet" type="text/css" href="styles.css">


<f:loadBundle basename="com.kiosk.clientname.resources.ApplicationResource" var="bundle"/>
<h:form id="loginForm" rendered="true">
<h:outputLabel rendered="true" for="userName">

<h:inputText value="#{up_User.objUpUser.userScreenName}" rendered="true"
required="true" id="userName" />
<h:outputLabel rendered="true" for="password">

<h:inputSecret value="#{up_User.objUpUser.userPassword}" rendered="true"
required="true" redisplay="false" id="password" />
<h:commandButton value="Login}" rendered="true"
action="#{up_User.loginUser}" id="submit" /> 


Urgent help will be appreciated...

also including faces-config.xml

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE faces-config PUBLIC "-//Sun Microsystems, Inc.//DTD JavaServer Faces Config 1.1//EN"


<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
<servlet-name>Faces Servlet</servlet-name>
<servlet-name>Faces Servlet</servlet-name>
<!-- This security constraint illustrates how JSP pages
with JSF components can be protected from
being accessed without going through the Faces Servlet.
The security constraint ensures that the Faces Servlet will
be used or the pages will not be processed. -->
<display-name>Restrict access to JSP pages</display-name>
<web-resource-name>Restrict access to JSP pages</web-resource-name>
<description>With no roles defined, no access granted</description>

Posts: 6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

It would be great if you could post any further information on this.. Do you see an error in your console? Is it a 404/500 error? Are you using jsf 1.2 ?DO you have jsf-api.jar and the jsf-impl.jar in your classpath and any dependent jars?
You showed up just in time for the waffles! And this tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
    Bookmark Topic Watch Topic
  • New Topic