3 Replies Latest reply on Jan 12, 2012 10:56 AM by undermanager

    JSF 2.0 + Richfaces 4.0.0

    Jack Robert Newbie



           I want to develope simple apication using the follwoing environment


      1. JSF 2.0

      2. Richfaces 4.0.0

      3. Facelet

      4. Tomcat 6.x



      What are the required jar?   ( faces-config.xml, web.xml ) ????

      Give me a reference link or metarial.


      Help me.

      Thanks in advance.

        • 1. Re: JSF 2.0 + Richfaces 4.0.0
          undermanager Newbie

          This should get you started with a bare-bones set-up.  You may be able to skip some sections; you may have to adapt others.


          Or, this one.  With screenshots!

          • 2. Re: JSF 2.0 + Richfaces 4.0.0
            Jack Robert Newbie

            Thansk for your response.


            Already i worked JSF1.2 + Richface 3.x + Netbeans IDE6.7.1.


            Now i want to create simple project in Netbeans IDE -> JSF2.0 + Richfaces + Facelet .


            I want to run my application in tomcat.


            i hope i will get solution..


            Help me.

            Thanks for your effort.

            • 3. Re: JSF 2.0 + Richfaces 4.0.0
              undermanager Newbie

              I assume you have already downloaded and installed the NetBeans "EE" bundle, which includes Tomcat. 


              OPTION 1 - Use Maven:


              Follow the guide I linked to above - except that when you have created your stand-alone Maven project, you can import it into NetBeans: File > New Project > Maven.


              There are various options for creating new Maven projects, and for importing existing Maven projects.  You will be importing an existing project.


              This is the simplest way to get exactly what you want, with no need to hunt around for the library dependencies you need.  This will also give you working examples of the config files you mentioned.


              OPTION 2 - Manual Approach:


              Alternatively, you can manually create a new empty web project in NetBeans.


              Go to File > New Project > Java Web > Web Application and hit "Next".


              Fill in the details for "Name and Location".


              In the "Server and Settings" section, choose Tomcat as your server.  Decide which version of Java EE you want/need.  Add in CDI support here, if you need that, also.


              In the "Frameworks" section, choose JavaServer Faces  You should see "JSF 2.0" displayed as the "Server Library".


              Click "Finish". 


              That will give you a new, empty JSF project in NetBeans.  Adding in RichFaces is simple, and is well documented elsewhere.  Basically, you need to download the RichFaces libraries (four RF JAR files, plus related dependencies), and link them into your project in the usual way.


              I recommend the Maven approach, as the simplest way to get a fully working set-up, with all the dependencies you need - no scrabbling around for missing JARs.