4 Replies Latest reply on Jan 24, 2012 10:10 AM by William Abbott

    Eclipse, RichFaces not working.

    William Abbott Newbie

      It's pretty much that simple. I'm very new to this so I'm not excatly sure what to ask, but I can describe my problem.

      The problem is this, I have rich faces elements in my web page, but when i run the web page, they do not display.

      I was told that most likely the libraries are not loading and that I may need to edit the faces-config.xml in the deployment folder of the project in the JBoss folder, but I'm not certain what I need to add to make sure those libraries load.

       

      Please see below for the web page code and faces-config code.

       

      Faces-Config.xml:

      <?xml version="1.0" encoding="UTF-8"?>

      <faces-config version="2.0" xmlns="http://java.sun.com/xml/ns/javaee"

      xmlns:xi="http://www.w3.org/2001/XInclude"

      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-facesconfig_2_0.xsd">

      <navigation-rule>

        <from-view-id>/index.xhtml</from-view-id>

        <navigation-case>

         <from-outcome>reload</from-outcome>

         <to-view-id>/index.xhtml</to-view-id>

        </navigation-case>

        <navigation-case>

         <from-outcome>success</from-outcome>

         <to-view-id>/UserControlPanel.xhtml</to-view-id>

        </navigation-case>

      </navigation-rule>

      <navigation-rule>

        <from-view-id>/users.xhtml</from-view-id>

        <navigation-case>

         <from-outcome>EmployeeNotFound</from-outcome>

         <to-view-id>/users.xhtml</to-view-id>

        </navigation-case>

        <navigation-case>

         <from-outcome>UnableToAdd</from-outcome>

         <to-view-id>/users.xhtml</to-view-id>

        </navigation-case>

        <navigation-case>

         <from-outcome>EmployeeAdded</from-outcome>

         <to-view-id>/index.xhtml</to-view-id>

        </navigation-case>

        <navigation-case>

         <from-outcome>back</from-outcome>

         <to-view-id>/index.xhtml</to-view-id>

        </navigation-case>

      </navigation-rule>

      <navigation-rule>

        <from-view-id>/UserControlPanel.xhtml</from-view-id>

        <navigation-case>

         <from-outcome>login</from-outcome>

         <to-view-id>/index.xhtml</to-view-id>

        </navigation-case>

        <navigation-case>

         <from-outcome>report</from-outcome>

         <to-view-id>/http://192.168.7.210/reports</to-view-id>

        </navigation-case>

      </navigation-rule>

      <navigation-rule>

        <from-view-id>/AllSkills.xhtml</from-view-id>

        <navigation-case>

         <from-outcome>skillFinish</from-outcome>

         <to-view-id>/UserControlPanel.xhtml</to-view-id>

        </navigation-case>

      </navigation-rule>

      <navigation-rule>

        <from-view-id>/admin.xhtml</from-view-id>

        <navigation-case>

         <from-outcome>login</from-outcome>

         <to-view-id>/index.xhtml</to-view-id>

        </navigation-case>

        <navigation-case>

         <from-outcome>back</from-outcome>

         <to-view-id>/UserControlPanel.xhtml</to-view-id>

        </navigation-case>

      </navigation-rule>

      </faces-config>

       

      Web Page:

       

      <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

      <html xmlns="http://www.w3.org/1999/xhtml"

            xmlns:h="http://java.sun.com/jsf/html"

            xmlns:f="http://java.sun.com/jsf/core"

            xmlns:ui="http://java.sun.com/jsf/facelets"

            xmlns:rich="http://richfaces.org/rich">

       

          <ui:composition template="/template.xhtml">

          <ui:define name="title">Tester Page for Random Things</ui:define>

          <ui:define name="content">

       

      <form>   

          <rich:panelMenu mode="ajax"

                      topGroupExpandedRightIcon="chevronUp"

                      topGroupCollapsedRightIcon="chevronDown"

                      groupExpandedLeftIcon="disc"

                      groupCollapsedLeftIcon="disc">

       

             <rich:panelMenuGroup label="Application Software" action="#{SkillBean.parentCat}">

            <rich:panelMenuItem label="AS Skills..." action="#{SkillBean.skillName}"/>

          </rich:panelMenuGroup>

         

             <rich:panelMenuGroup label="Languages" action="#{SkillBean.parentCat}">

              <rich:panelMenuItem label="Lang Skills..." action="#{SkillBean.skillName}"/>

          </rich:panelMenuGroup>

          </rich:panelMenu>   

      <br></br>

      <rich:progressBar id="progressbar" label="Progress Bar"></rich:progressBar>

       

      <rich:tab label="Tabbed Panel">

      <rich:tabPanel id="tabbedpanel">

          <rich:tab label="Applications"/>

          <rich:tab label="Languages"/>

      </rich:tabPanel>

      </rich:tab>

      <br></br>

      <rich:toolbar>

          <rich:toolbarGroup value="#{skillBean.parentCat}"></rich:toolbarGroup>

      </rich:toolbar>

       

       

       

      </form>   

          <br></br>

          </ui:define>

          </ui:composition>

      </html>

       

      Any advice provided would be very helpful.

       

      Thank you.