aspose file tools*
The moose likes JSF and the fly likes Very simple error Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » JSF
Bookmark "Very simple error" Watch "Very simple error" New topic
Author

Very simple error

Dura Hurtado
Ranch Hand

Joined: Feb 16, 2011
Posts: 120
When I try to run the app the index.jsp file shows the next mistake:

org.apache.jasper.JasperException: Ha sucedido una excepción al procesar la página JSP /bienvenido.jsp en línea 21

18: <TH CLASS="TITLE">Bienvenido a JSF</TH>
19: </TR>
20: </TABLE>
21: <h:commandButton id="k" action="nextPage" value="SendJSF" /></form>

THE CODE BELLOW:
----------------------


<?xml version="1.0" encoding="ISO-8859-1" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<%@ taglib uri="http://java.sun.com/jsf/html" prefix="h"%>
<%@ taglib uri="http://java.sun.com/jsf/core" prefix="f"%>


<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
<title>Insert title here</title>
</head>
<body>
<form method="get" action="control">
<TABLE BORDER=5 ALIGN="CENTER">
<TR>
<TH CLASS="TITLE">Bienvenido a JSF</TH>
</TR>

</form>
<h:commandButton id="k" action="nextPage" value="SendJSF" />
</TABLE>


</body>
</html>

Thanks
Wouter Oet
Saloon Keeper

Joined: Oct 25, 2008
Posts: 2700

I don't know much about JSF but shouldn't the commandbutton be inside of a form?


"Any fool can write code that a computer can understand. Good programmers write code that humans can understand." --- Martin Fowler
Please correct my English.
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 16250
    
  21

The commandButton must be inside a JSF form element and the JSF form element must be inside a JSF view element.

And, as far as it goes, it's really rather late in the season to be using JSP form for JSF view definitions.


Customer surveys are for companies who didn't pay proper attention to begin with.
Dura Hurtado
Ranch Hand

Joined: Feb 16, 2011
Posts: 120
Tim Holloway wrote:The commandButton must be inside a JSF form element and the JSF form element must be inside a JSF view element.

And, as far as it goes, it's really rather late in the season to be using JSP form for JSF view definitions.


Thanks it´s very useful.
 
 
subject: Very simple error