Installing JSF 1.1 in TOMCAT 5.5.23

In this section, we will learn about installation of JSF 1.1 to TOMCAT 5.5.23. Java Server Faces (JSF) requires some steps to follow while configuring it in TOMCAT.

Installing JSF 1.1 in TOMCAT 5.5.23

Installing JSF 1.1 in TOMCAT 5.5.23

        

In this section, we will learn about installation of JSF 1.1 to TOMCAT 5.5.23. Java Server Faces (JSF) requires some steps to follow while configuring it in TOMCAT. Here we are considering you comfortable installing the tomcat. There is nothing much to do to install JSF if you have already installed and configured tomcat 5.5.23. We require 

  1. Jdk1.6.0
  2. Tomcat 5.5.23
  3. Jsf 1.1
  4. Servlet 2.3
  5. Jsp 1.2

 The steps required to make your JSF application run are summarized below :

  1. Download zip file of tomcat 5.5.23 from http://tomcat.apache.org/download-55.cgi#5.5.23.
  2. Extract this file to the directory of your choice (suppose c:/tomcat) (remember to set JAVA_HOME variable).
    You will get 9 sub-folders into this tomcat directory :
    1)bin
    2)common
    3)conf
    4)logs
    5)server
    6)shared
    7)temp
    8)web-apps
    9)work
    and some files.
  3. Download zipped file of jsf 1.1 Reference Implementation from http://java.sun.com/javaee/javaserverfaces/download.html.
  4. Extract the above zipped file of jsf 1.1 to the directory of your choice (suppose c:/jsf).
    You will get 7 sub-folders in this jsf folder :
    1) docs 
    2) javadocs
    3) lib
    4) metadata
    5) renderkitdocs
    6) samples
    7) tlddocs
    and some files.
  5. Copy all jar files from jsf/lib directory of above extracted file to tomcat/common/lib directory.
  6. Copy two jar  files "jstl.jar" and "standard.jar" from tomcat/webapps/jsp-examples/WEB-INF/lib directory  to tomcat/common/lib directory.
  7. Set class path for these jar files.
  8. Start tomcat.

After configuring JSF in tomcat, we can create and run JSF application. After making any changes in application, its better restart the tomcat before running the application. If you want to run a sample application provided by JSF reference implementation then

  1. go to  jsf/samples folder
  2. copy any war file from here to tomcat/webapps
  3. restart tomcat server

This war file gets extracted automatically to the directory structure with the same name of war file. Now you can run this application in tomcat and  you can follow the directory structure of these applications to make your own application. In this tutorial, all steps have been described in simple manner by a simple application "SimpleHelloByEnteringName".