How to navigate from one jsf to another in eclipse
Hi there is my jsf code...
<%@ page language="java" contentType="text/html; charset=ISO-8859-1" pageEncoding="ISO-8859-1"%>
<%@ taglib prefix="f" uri="http://java.sun.com/jsf/core"%>
<%@ taglib prefix="h" uri="http://java.sun.com/jsf/html"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Insert title here</title>
</head>
<body>
<f:view>
<b>
<h:outputText value="USER DETAILS FORM"> </h:outputText>
</b>
<p>
<h:messages style="color: blue"/>
</p>
<h:form id="UserDetail">
<h:panelGrid columns="2">
<h:outputText value="Name :"></h:outputText>
<h:inputText id="name" value="#{userBean.name}"
required="true"
requiredMessage="Please enter your Name"
validatorMessage="Please enter more than 3 characters for name">
<f:validateLength minimum="3"/>
</h:inputText>
</h:panelGrid>
<h:commandButton value="Submit" action="success"></h:commandButton>
</h:form>
</f:view>
</body>
</html>
Hello guys i have been using the above code for my welcome page which ask for user name and after submitting the form it navigate to the following page :-
<%@ page language="java" contentType="text/html; charset=ISO-8859-1" pageEncoding="ISO-8859-1"%>
<%@ taglib prefix="f" uri="http://java.sun.com/jsf/core"%>
<%@ taglib prefix="h" uri="http://java.sun.com/jsf/html"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Insert title here</title>
</head>
<body>
<f:view>
<h3>
<h:outputText value="Welcome"/>
<h:outputText value="#{userBean.name}"></h:outputText> To Our database.
</h3>
</f:view>
</body>
</html>
The above code is working fine in NETBEANS.. but when i run this in eclipse it stays on the first page only even after submitting the form...
I have checked it many time the navigation rules are also defined properly as folows :-
<navigation-rule>
<from-view-id>/JSF/UserDetail.jsp</from-view-id>
<navigation-case>
<from-outcome>success</from-outcome>
<to-view-id>/JSF/Welcome.jsp</to-view-id>
</navigation-case>
</navigation-rule>
Pls help me finding the solution for this problem..
Thank You
View Answers
April 13, 2012 at 1:08 PM
Related Tutorials/Questions & Answers:
Adding Navigation in JSF Application explains
how to
navigate from one jsp page to
another jsp in
JSF application. The page... This file contains
one or more navigation cases.
You can map action
from... Adding Navigation in
JSF Application
Advertisements
How to forward the control from one jsp to another?How to forward the control
from one jsp to
another? Hi!
This is Prasad Jandrajupalli.
I have the 3 JSP's, but I want communicate with each... is not communicate with the Third JSP.
I want forward the control
from first jsp to second
how to pass a string from one class to anotherhow to pass a string
from one class to another hi all, Good morning... string
from one class to
another.
import java.util.*;
class A{
static String... string
from one class to
another.
import java.io.*;
class Class1 {
public
How to pass variable from one class to another in javaHow to pass variable
from one class to
another in java
How to pass variable
from one class to
another in java?
Example:
public class...;
}
}
//
Another class Class2.
public class Class2 {
public static void main(String
How To Pass data from one GUI to another in java swingHow To Pass data
from one GUI to
another in java swing I'm new to java and part of our assignment is to build a GUI and display a result set
from data input. I'm stuck at
how to get the user's input
from JTextFields and combobox
File copy from one directory to another in javaFile copy
from one directory to
another in java I am trying to find very good code example for copying a file
from one directory to
another...
from a directory to
another directory.
How to achieve this? Is there any API
update one table from another tableupdate
one table
from another table hello, i need to update
one table fields by using
another table fields. I have to tables Products.... for example TotalQuantity field
from Products table should be updated if i
passing data from one jframe to anotherpassing data
from one jframe to another I have two JFrame,built by using the GUI Editor netbeans 6.9.i have to pass a data
from a Jtextfield in the first Jframe to
another JLabel in the other JFrame.Can you please help me,
how copying data from one table to anothercopying data
from one table to another i need to copy data
from one table to
another table..
i.e the 1st eid of employee table must be copied to the 1st eid in appusers table, 2nd eid of employee to the 2nd eid of appusers
to bring checked data from one page to anotherto bring checked data
from one page to another thanks for your help... there is
one jsp page , on it there is a link, on click of which it is opening second... fetching data
from the database on second jsp page with checkbox corresponding each
problem in sending data from one ip to another ip in JAVAproblem in sending data
from one ip to
another ip in JAVA Hi guys .
this is naveen kumar...i need a help.
i want to connect
one ip to
another ip... device in JAVA.
i know
how to ping but don't
how to send the msg's to
another IP
calling one jap page from another jsp pagecalling
one jap page
from another jsp page i created a button in
one jsp page i need to call
another jsp page as an action to that button. so
how can i call.. plz any
one explain. its urgent
how to use string of one class into another Classhow to use string of
one class into
another Class I created textField(JTextField t1=new JTextField();(it is in ClassA. The input of this textField i.e t1.getText() is to be used in different(
another Class say in ClassB.
How can
how to change password into one jsp to another jsphow to change password into
one jsp to
another jsp i have two jsps in
one jsp i give
one password and confirm password, in
another jsp i want change my password compare with 1st jsp
how to write code please give me answer?
calling one jsp from another jsp - JSP-Servletcalling
one jsp
from another jsp Hi All,
In my web application... in two.jsp by using jsp declarative tag. Now
from one.jsp file I want to call... start
from where we call this two.jsp files method. i.e. in one.jsp file at line
Java - Copying one file to another;
This example illustrates
how to copy contents
from one... which copies the contents
from one specified file to
another specified file... for buffering the contents of
one file and
write to
another specified file
from jsf: generate another panelGridjsf: generate
another panelGrid hello
the following is my code
print("code sample");
<%@ taglib uri="http://java.sun.com/
jsf/html" prefix="h"%>
<%@ taglib uri="http://java.sun.com/
jsf/core" prefix="f"%>
how to focus on the new window opened from JSF ?how to focus on the new window opened
from JSF ? Hi guys,
I have commandLink with action which using javascript to open a new window(window.open()). Problem is, the new window opens at background behind the current window
How to call the run method from another class?How to call the run method
from another class? Sorry, if this is a stupid question.
I would like to find out
how to call the run method... run() {
new FereastraPrincipala().setVisible(true);
from the class
Copy one file into anotherCopy
one file into
another
In this section, you will learn
how to copy content of
one file into
another
file. We will perform this operation by using...;This string is copied
from one file to
another\n");
bf.close();
InputStream
How to write content of one file to another file. the use of
CheckedOutputStream
class. The CheckedOutputStream class is
from... the
associated stream.
void
write(int b)
Method writes
one... is : 1836825431
Content of
one file successfully written in other file