javaserverfaces-spec-public
  1. javaserverfaces-spec-public
  2. JAVASERVERFACES_SPEC_PUBLIC-1213

f:viewParam doesn't work when using xmlns:f="http://xmlns.jcp.org/jsf/core"

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Critical Critical
    • Resolution: Duplicate
    • Affects Version/s: 2.2
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None
    • Environment:

      JavaEE 7 maven web application with JSF 2.2
      GlassFish Server Open Source Edition 4.0 (build 89)

      Description

      Given

      <?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:f="http://xmlns.jcp.org/jsf/core">
      
          <f:metadata>
              <f:viewParam name="id" value="#{myBean.id}" />
          </f:metadata>
      </html>
      

      myBean.id will never be populated. However, changing the xmlns to the following fixes it:

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

      Glassfish 4 should support the new xmlns for an EE7 project (JSF version 2.2).

        Issue Links

          Activity

            People

            • Assignee:
              Manfred Riem
              Reporter:
              irinipaci
            • Votes:
              1 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: