2 Replies Latest reply on Oct 26, 2006 3:22 PM by Tai Thach

    JSTL on JBoss 4.0.2

    Tai Thach Newbie

      I'm trying to deploy the simple hello1 web project from the J2EE 1.4 tutorial on JBoss 4.0.2. Although it deploys fine and I can access the page, the behavior is not correct. When I enter some text and hit submit, then the text "Hello <some text>" should also be displayed on the page. However, this does not happen, which leaves me to believe that the JSTL tags are not being evaluated.

      This is the index.jsp:

      <%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
      <%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn" %>
      <body bgcolor="white">
      <img src="duke.waving.gif">
      <h2>Hello, my name is Duke. What's yours?</h2>
      <form method="get">
      <input type="text" name="username" size="25">
      <input type="submit" value="Submit">
      <input type="reset" value="Reset">
      <c:if test="${fn:length(param.username) > 0}" >
       <h2><font color="black">Hello, ${param.username}!</font></h2>

      This is the web.xml in use:
      <?xml version="1.0" encoding="UTF-8"?>
      <!DOCTYPE web-app
       PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"

      I've packaged everything in a war with the web.xml file under WEB-INF, the tld files under WEB-INF/tld and the jstl.jar and standard.jar under WEB-INF/lib.

      Any ideas on what's going on?