You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 7 Next »

Step 1: Take a look at the examples

Your first step with Apache MyFaces should be to have a look at our examples application. In the following links (kindly hosted by Irian Solutions GmbH) you will find demo applications running with MyFaces.

You can deploy the examples application for yourself. All you need to do to get up and running is to follow the steps below!:

Step 2: Deploy MyFaces Tomahawk example application.

The most simple example you can try is the ones bundled with tomahawk, which at the begining of MyFaces project was the example application bundled with MyFaces Core.

What you need for the Examples Application

  • A web server like Apache Tomcat. The example shown runs on 5.x, 6.x or 7.x, but note JSF 1.2 and later versions requires tomcat 6.x or upper. Download it from here.
  • Go to Tomahawk download page and download the webapps assembly (tomahawk-X.X.X-examples.zip or tomahawk-X.X.X-examples.tgz)

Installing and Running the Examples

  • Unpack the MyFaces examples archive tomahawk-X.X.X-examples.zip (or tomahawk-X.X.X-examples.tgz) to a directory of your choice.
  • Remove any previous MyFaces webapps from your Tomcat installation and clean up your Tomcat work dir. Also make sure that there is no jsf-api.jar or jsf-impl.jar (i.e. Suns API and implementation) in the classpath or in one of Tomcat's lib directories (for Tomcat 5.x look on common/lib or shared/lib, in tomcat 6.x or 7.x look on /lib folder).
  • Copy the file myfaces-example-simple.war (or any of the other example war-files, myfaces-example-simple20.war for JSF 2.0 variant) to the webapps dir of your Tomcat installation directory - and check once more that there is no old myfaces-examples directory there (wink)
  • Start Tomcat, if its not already running.
  • Start your browser and enjoy it at http://localhost:8080/myfaces-example-simple20.
  • No labels