• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Very simple error

 
Dura Hurtado
Ranch Hand
Posts: 120
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
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
Posts: 2700
IntelliJ IDE Opera
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I don't know much about JSF but shouldn't the commandbutton be inside of a form?
 
Tim Holloway
Saloon Keeper
Pie
Posts: 18098
50
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
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.
 
Dura Hurtado
Ranch Hand
Posts: 120
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
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.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic