1 2 Previous Next 23 Replies Latest reply on Dec 14, 2015 4:29 AM by michpetrov

    Moved to RichFaces 4.5.5 Final (deployed on WildFly 8.2 Final) tabPanel & tab won't display

    notify

      Haven't used RichFaces since v.3.x with Seam 2.x a couple of years ago. Now have the requirement for an Application with a web front end, using Java 7, CDI /JBoss Weld and RichFaces 4.5 all deployed on WildFly 8.2. final.

       

      Just trying a simple home page as a Facelet (XHTML) with a RichFaces tabPanel and multiple tabs.

       

      It deploys fine but when I bring it up in Google Chrome it displays what looks like the TabPanelTabs component IDs:

       

      (I've number of live sites using RF 3.x and Seam 2.x)

       

      Thanks.

       

      In browser:

       

       

      tab1tab2
      «

       

      »

       

      tab1

       

      My web.xml is:

       

      <?xml version="1.0" encoding="UTF-8"?>
      <web-app xmlns="http://xmlns.jcp.org/xml/ns/javaee"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee http://xmlns.jcp.org/xml/ns/javaee/web-app_3_1.xsd"
         version="3.1">

       

         <context-param>

         <param-name>javax.faces.PROJECT_STAGE</param-name>

         <param-value>Development</param-value>

         </context-param>

       

         <context-param>

         <param-name>org.richfaces.SKIN</param-name>

         <param-value>blueSky</param-value>

         </context-param>

       

         <context-param>

         <param-name>org.richfaces.queue.enabled</param-name>

         <param-value>false</param-value>

         </context-param>


         <welcome-file-list>

         <welcome-file>index.xhtml</welcome-file>

         </welcome-file-list>

       

         <!-- ACTIVATE - JAVAX JSF Servlet -->
         <servlet>

         <servlet-name>Faces Servlet</servlet-name>

         <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>

         <load-on-startup>1</load-on-startup>

         </servlet>

       

         <servlet-mapping>

         <servlet-name>Faces Servlet</servlet-name>

         <url-pattern>*.xhtml</url-pattern>

         </servlet-mapping>

       

      </web-app>


      XHTML:


      <?xml version="1.0" encoding="UTF-8"?>
      <!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:a4j="http://richfaces.org/a4j"
         xmlns:rich="http://richfaces.org/rich">

       

      <ui:composition>

         <rich:tabPanel switchType="client">

         <rich:tab header="tab1">tab1</rich:tab>

         <rich:tab header="tab2">tab2</rich:tab>

         </rich:tabPanel>

         <a4j:log popup="true" level="ALL" style="width: 800px; height: 300px;"></a4j:log>

      </ui:composition>

      </html>

        • 1. Re: Moved to RichFaces 4.5 tabPanel & tab won't display
          notify

          I've taken the tabPanel from the RF4 showcase:

           

          <!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:a4j="http://richfaces.org/a4j" xmlns:rich="http://richfaces.org/rich">

           

          <ui:composition>

              <h:form>

                  <strong>External controls for switching the panel:</strong>

                  <br />

                  <h:commandLink value="Previous tab">

                      <rich:toggleControl targetPanel="tp" targetItem="@prev" />

                  </h:commandLink>

                  <h:outputText value=" | " />

                  <h:commandLink value="Next tab">

                      <rich:toggleControl targetPanel="tp" targetItem="@next" />

                  </h:commandLink>

                  <br />

                  <br />

                  <rich:tabPanel switchType="ajax" id="tp" headerPosition="top" headerLocation="center">

                      <rich:tab header="First">

                          Here is tab #1

                      </rich:tab>

                      <rich:tab header="Second">

                          Here is tab #2

                      </rich:tab>

                      <rich:tab header="Third">

                          Here is tab #3

                      </rich:tab>

                  </rich:tabPanel>

           

              </h:form>

          </ui:composition>

          </html>

           

          This displays:


          External controls for switching the panel:

          Previous tab | Next tab

           

          Here is tab #1 Here is tab #2 Here is tab #3

           

          Any pointers/ideas?

           

          TIA

          • 2. Re: Moved to RichFaces 4.5 tabPanel & tab won't display
            michpetrov

            Looks like the resources are missing, do you have <h:head> on your page?

            • 3. Re: Moved to RichFaces 4.5 tabPanel & tab won't display
              notify

              If I add:

               

              <h:head></h;head>

               

              It says 'cannot resolve symbol'

               

              Though I have:

               

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

               

              If I use <head></head>

               

              It makes no difference.

               

              Thanks.

              • 4. Re: Moved to RichFaces 4.5 tabPanel & tab won't display
                michpetrov

                Roger Lee wrote:

                 

                If I add:

                 

                <h:head></h;head>

                 

                It says 'cannot resolve symbol'

                I'd assume that's because of the semicolon.

                • 5. Re: Moved to RichFaces 4.5 tabPanel & tab won't display
                  notify

                  That was just a typo posting here

                   

                  It's:


                  <h:head></h:head>


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


                  jsf/html doesn't contain h:head

                   

                  Am I missing a JSF 2 JAR?

                  • 6. Re: Moved to RichFaces 4.5 tabPanel & tab won't display
                    michpetrov

                    If a missing JAR was the problem you wouldn't start the application (and it would complain about h:form as well). What's the stacktrace of the error? It should say something like "prefix h is not bound" if it cannot recognize the tag, not "cannot resolve symbol".

                    • 7. Re: Moved to RichFaces 4.5 tabPanel & tab won't display
                      notify

                      There's no stack error, starts fine in WildFly 8.2 final. What I can't understand why <h:head> is not found (in IntelliJ IDEA 14).

                       

                      WildFly log:

                       

                      =========================================================================

                       

                        JBoss Bootstrap Environment

                       

                        JBOSS_HOME: /usr/local/opt/wildfly-as/libexec

                       

                        JAVA: java

                       

                        JAVA_OPTS:  -server -Xms64m -Xmx512m -XX:MaxPermSize=256m -Djava.net.preferIPv4Stack=true -Djboss.modules.system.pkgs=org.jboss.byteman -Djava.awt.headless=true

                       

                      =========================================================================

                       

                      14:59:41,608 INFO  [org.jboss.modules] (main) JBoss Modules version 1.3.3.Final

                      14:59:41,835 INFO  [org.jboss.msc] (main) JBoss MSC version 1.2.2.Final

                      14:59:41,891 INFO  [org.jboss.as] (MSC service thread 1-6) JBAS015899: WildFly 8.2.0.Final "Tweek" starting

                      14:59:42,615 INFO  [org.jboss.as.server] (Controller Boot Thread) JBAS015888: Creating http management service using socket-binding (management-http)

                      14:59:42,630 INFO  [org.xnio] (MSC service thread 1-1) XNIO version 3.3.0.Final

                      14:59:42,636 INFO  [org.xnio.nio] (MSC service thread 1-1) XNIO NIO Implementation Version 3.3.0.Final

                      14:59:42,659 INFO  [org.wildfly.extension.io] (ServerService Thread Pool -- 31) WFLYIO001: Worker 'default' has auto-configured to 16 core threads with 128 task threads based on your 8 available processors

                      14:59:42,660 INFO  [org.jboss.as.clustering.infinispan] (ServerService Thread Pool -- 32) JBAS010280: Activating Infinispan subsystem.

                      14:59:42,667 INFO  [org.jboss.as.security] (ServerService Thread Pool -- 45) JBAS013171: Activating Security Subsystem

                      14:59:42,667 WARN  [org.jboss.as.txn] (ServerService Thread Pool -- 46) JBAS010153: Node identifier property is set to the default value. Please make sure it is unique.

                      14:59:42,675 INFO  [org.jboss.as.security] (MSC service thread 1-13) JBAS013170: Current PicketBox version=4.0.21.Final

                      14:59:42,677 INFO  [org.jboss.as.naming] (ServerService Thread Pool -- 40) JBAS011800: Activating Naming Subsystem

                      14:59:42,677 INFO  [org.jboss.as.jsf] (ServerService Thread Pool -- 38) JBAS012615: Activated the following JSF Implementations: [main]

                      14:59:42,710 INFO  [org.jboss.remoting] (MSC service thread 1-1) JBoss Remoting version 4.0.6.Final

                      14:59:42,715 INFO  [org.wildfly.extension.undertow] (ServerService Thread Pool -- 47) JBAS017502: Undertow 1.1.0.Final starting

                      14:59:42,715 INFO  [org.wildfly.extension.undertow] (MSC service thread 1-14) JBAS017502: Undertow 1.1.0.Final starting

                      14:59:42,722 INFO  [org.jboss.as.webservices] (ServerService Thread Pool -- 48) JBAS015537: Activating WebServices Extension

                      14:59:42,732 INFO  [org.jboss.as.connector.subsystems.datasources] (ServerService Thread Pool -- 27) JBAS010404: Deploying non-JDBC-compliant driver class com.mysql.jdbc.Driver (version 5.1)

                      14:59:42,734 INFO  [org.jboss.as.connector.logging] (MSC service thread 1-12) JBAS010408: Starting JCA Subsystem (IronJacamar 1.1.9.Final)

                      14:59:42,742 INFO  [org.jboss.as.connector.deployers.jdbc] (MSC service thread 1-10) JBAS010417: Started Driver service with driver-name = MySQL

                      14:59:42,774 INFO  [org.jboss.as.naming] (MSC service thread 1-16) JBAS011802: Starting Naming Service

                      14:59:42,774 INFO  [org.jboss.as.mail.extension] (MSC service thread 1-13) JBAS015400: Bound mail session [java:jboss/mail/Default]

                      14:59:42,836 INFO  [org.wildfly.extension.undertow] (ServerService Thread Pool -- 47) JBAS017527: Creating file handler for path /usr/local/opt/wildfly-as/libexec/welcome-content

                      14:59:42,862 INFO  [org.wildfly.extension.undertow] (MSC service thread 1-4) JBAS017525: Started server default-server.

                      14:59:42,887 INFO  [org.wildfly.extension.undertow] (MSC service thread 1-15) JBAS017531: Host default-host starting

                      14:59:42,935 INFO  [org.jboss.as.connector.subsystems.datasources] (MSC service thread 1-11) JBAS010400: Bound data source [java:jboss/datasources/NOTiFYPiNPOiNTDatasource]

                      14:59:42,935 INFO  [org.jboss.as.connector.subsystems.datasources] (MSC service thread 1-9) JBAS010400: Bound data source [java:jboss/datasources/NOhaglDatasource]

                      14:59:42,957 INFO  [org.wildfly.extension.undertow] (MSC service thread 1-6) JBAS017519: Undertow HTTP listener default listening on /127.0.0.1:8080

                      14:59:43,099 INFO  [org.jboss.as.server.deployment.scanner] (MSC service thread 1-14) JBAS015012: Started FileSystemDeploymentService for directory /usr/local/opt/wildfly-as/libexec/standalone/deployments

                      14:59:43,102 INFO  [org.jboss.as.server.deployment] (MSC service thread 1-9) JBAS015876: Starting deployment of "NOhagl_ear.ear" (runtime-name: "NOhagl_ear.ear")

                      14:59:43,544 INFO  [org.jboss.ws.common.management] (MSC service thread 1-4) JBWS022052: Starting JBoss Web Services - Stack CXF Server 4.3.2.Final

                      14:59:44,199 INFO  [org.jboss.as.server.deployment] (MSC service thread 1-12) JBAS015973: Starting subdeployment (runtime-name: "web.war")

                      14:59:44,199 INFO  [org.jboss.as.server.deployment] (MSC service thread 1-7) JBAS015973: Starting subdeployment (runtime-name: "ejb.jar")

                      14:59:44,240 INFO  [org.jboss.as.jpa] (MSC service thread 1-8) JBAS011401: Read persistence.xml for NOhaglPersistenceUnit

                      14:59:44,353 INFO  [org.jboss.as.jpa] (MSC service thread 1-9) JBAS011401: Read persistence.xml for NOhaglPersistenceUnit

                      14:59:44,446 INFO  [org.jboss.as.jpa] (ServerService Thread Pool -- 50) JBAS011409: Starting Persistence Unit (phase 1 of 2) Service 'NOhagl_ear.ear/ejb.jar#NOhaglPersistenceUnit'

                      14:59:44,446 INFO  [org.jboss.as.jpa] (ServerService Thread Pool -- 51) JBAS011409: Starting Persistence Unit (phase 1 of 2) Service 'NOhagl_ear.ear/web.war#NOhaglPersistenceUnit'

                      14:59:44,450 INFO  [org.jboss.weld.deployer] (MSC service thread 1-9) JBAS016002: Processing weld deployment NOhagl_ear.ear

                      14:59:44,453 INFO  [org.hibernate.jpa.internal.util.LogHelper] (ServerService Thread Pool -- 51) HHH000204: Processing PersistenceUnitInfo [

                        name: NOhaglPersistenceUnit

                        ...]

                      14:59:44,453 INFO  [org.hibernate.jpa.internal.util.LogHelper] (ServerService Thread Pool -- 50) HHH000204: Processing PersistenceUnitInfo [

                        name: NOhaglPersistenceUnit

                        ...]

                      14:59:44,515 INFO  [org.hibernate.validator.internal.util.Version] (MSC service thread 1-9) HV000001: Hibernate Validator 5.1.3.Final

                      14:59:44,521 INFO  [org.hibernate.Version] (ServerService Thread Pool -- 51) HHH000412: Hibernate Core {4.3.7.Final}

                      14:59:44,522 INFO  [org.hibernate.cfg.Environment] (ServerService Thread Pool -- 51) HHH000206: hibernate.properties not found

                      14:59:44,523 INFO  [org.hibernate.cfg.Environment] (ServerService Thread Pool -- 51) HHH000021: Bytecode provider name : javassist

                      14:59:44,606 INFO  [org.jboss.weld.deployer] (MSC service thread 1-6) JBAS016002: Processing weld deployment ejb.jar

                      14:59:44,636 INFO  [org.jboss.weld.deployer] (MSC service thread 1-6) JBAS016002: Processing weld deployment web.war

                      14:59:44,696 INFO  [org.jboss.as.connector.deployers.jdbc] (MSC service thread 1-10) JBAS010404: Deploying non-JDBC-compliant driver class com.mysql.jdbc.Driver (version 5.1)

                      14:59:44,697 INFO  [org.jboss.as.connector.deployers.jdbc] (MSC service thread 1-10) JBAS010404: Deploying non-JDBC-compliant driver class com.mysql.fabric.jdbc.FabricMySQLDriver (version 5.1)

                      14:59:44,698 INFO  [org.jboss.weld.deployer] (MSC service thread 1-10) JBAS016005: Starting Services for CDI deployment: NOhagl_ear.ear

                      14:59:44,724 INFO  [org.jboss.weld.Version] (MSC service thread 1-10) WELD-000900: 2.2.6 (Final)

                      14:59:44,737 INFO  [org.jboss.as.connector.deployers.jdbc] (MSC service thread 1-16) JBAS010417: Started Driver service with driver-name = NOhagl_ear.ear_com.mysql.jdbc.Driver_5_1

                      14:59:44,737 INFO  [org.jboss.as.connector.deployers.jdbc] (MSC service thread 1-11) JBAS010417: Started Driver service with driver-name = NOhagl_ear.ear_com.mysql.fabric.jdbc.FabricMySQLDriver_5_1

                      14:59:44,738 INFO  [org.jboss.weld.deployer] (MSC service thread 1-2) JBAS016008: Starting weld service for deployment NOhagl_ear.ear

                      14:59:44,852 INFO  [org.jboss.as.jpa] (ServerService Thread Pool -- 50) JBAS011409: Starting Persistence Unit (phase 2 of 2) Service 'NOhagl_ear.ear/web.war#NOhaglPersistenceUnit'

                      14:59:44,852 INFO  [org.jboss.as.jpa] (ServerService Thread Pool -- 51) JBAS011409: Starting Persistence Unit (phase 2 of 2) Service 'NOhagl_ear.ear/ejb.jar#NOhaglPersistenceUnit'

                      14:59:44,913 INFO  [org.hibernate.annotations.common.Version] (ServerService Thread Pool -- 51) HCANN000001: Hibernate Commons Annotations {4.0.4.Final}

                      14:59:45,153 INFO  [org.hibernate.dialect.Dialect] (ServerService Thread Pool -- 50) HHH000400: Using dialect: org.hibernate.dialect.MySQL5Dialect

                      14:59:45,153 INFO  [org.hibernate.dialect.Dialect] (ServerService Thread Pool -- 51) HHH000400: Using dialect: org.hibernate.dialect.MySQL5Dialect

                      14:59:45,325 INFO  [org.hibernate.hql.internal.ast.ASTQueryTranslatorFactory] (ServerService Thread Pool -- 51) HHH000397: Using ASTQueryTranslatorFactory

                      14:59:45,325 INFO  [org.hibernate.hql.internal.ast.ASTQueryTranslatorFactory] (ServerService Thread Pool -- 50) HHH000397: Using ASTQueryTranslatorFactory

                      14:59:46,585 INFO  [javax.enterprise.resource.webcontainer.jsf.config] (MSC service thread 1-10) Initializing Mojarra 2.2.8-jbossorg-1 20140822-1131 for context '/NOhaglWeb'

                      14:59:47,335 INFO  [javax.enterprise.resource.webcontainer.jsf.config] (MSC service thread 1-10) Monitoring file:/usr/local/opt/wildfly-as/libexec/standalone/tmp/vfs/deployment/deployment33cf2470c53f1966/web.war-3697299fd320d12d/WEB-INF/faces-config.xml for modifications

                      14:59:47,376 INFO  [org.wildfly.extension.undertow] (MSC service thread 1-10) JBAS017534: Registered web context: /NOhaglWeb

                      14:59:47,409 INFO  [org.jboss.as.server] (Controller Boot Thread) JBAS018559: Deployed "NOhagl_ear.ear" (runtime-name : "NOhagl_ear.ear")

                      14:59:47,429 INFO  [org.jboss.as] (Controller Boot Thread) JBAS015961: Http management interface listening on http://127.0.0.1:9990/management

                      14:59:47,429 INFO  [org.jboss.as] (Controller Boot Thread) JBAS015951: Admin console listening on http://127.0.0.1:9990

                      14:59:47,429 INFO  [org.jboss.as] (Controller Boot Thread) JBAS015874: WildFly 8.2.0.Final "Tweek" started in 6058ms - Started 350 of 416 services (108 services are lazy, passive or on-demand)

                       

                      • 8. Re: Moved to RichFaces 4.5 tabPanel & tab won't display
                        michpetrov

                        You said there was an error when you added <h:head> and now you're saying it starts fine so where is the problem?

                        • 9. Re: Moved to RichFaces 4.5 tabPanel & tab won't display
                          notify

                          IntelliJ IDEA 14 said 'cannot resolve symbol' referring to <h:head>

                           

                          However JBoss WildFly started fine (see above).

                          • 10. Re: Moved to RichFaces 4.5 tabPanel & tab won't display
                            pjotrovsky

                            I`m sorry to interfere you discussion, but can you please check your *faces-config.xml* and make sure it complies with JSF 2.x spec, like for example:http://www.oracle.com/webfolder/technetwork/jsc/xml/ns/javaee/web-facesconfig_2_2.xsd?

                            • 11. Re: Moved to RichFaces 4.5 tabPanel & tab won't display
                              michpetrov

                              Roger Lee wrote:

                               

                              IntelliJ IDEA 14 said 'cannot resolve symbol' referring to <h:head>

                               

                              However JBoss WildFly started fine (see above).

                              Does the page display correctly or not, the IDE glitching isn't really a problem.

                              • 12. Re: Moved to RichFaces 4.5 tabPanel & tab won't display
                                notify

                                NO. As posting above I see:

                                 

                                In browser:

                                 

                                 

                                 

                                tab1tab2
                                «

                                 

                                »

                                 

                                tab1

                                 

                                 

                                And from F4 Show Case Tabs code I see:

                                 

                                External controls for switching the panel:

                                Previous tab | Next tab

                                 

                                Here is tab #1 Here is tab #2 Here is tab #3

                                - See more at: https://developer.jboss.org/thread/258278#sthash.y2qt1RoP.dpuf

                                • 13. Re: Moved to RichFaces 4.5 tabPanel & tab won't display
                                  notify

                                  No problem, all help gratefully received:

                                   

                                  faces-config.xml

                                   

                                  <?xml version='1.0' encoding='UTF-8'?>
                                  <faces-config version="2.2" xmlns="http://xmlns.jcp.org/xml/ns/javaee"
                                     xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
                                     xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee
                                    http://xmlns.jcp.org/xml/ns/javaee/web-facesconfig_2_2.xsd">

                                   

                                  </faces-config>


                                  Is anything else need in faces-config.xml?


                                  • 14. Re: Moved to RichFaces 4.5 tabPanel & tab won't display
                                    pjotrovsky

                                    Oh, then you should consider changing the namespaces in your templates as described in JSF 2.2: New namespaces | JSFlive: Michael Kurz's JSF Weblog since you are targeting JSF 2.2.

                                    1 2 Previous Next