0

I am not sure why but I am using JSF 2.2 (Mojarra 2.2.6 implementation) but the implicit variable flowScope is not being recognized.

Here is the error:

/protected/pages/certificateWizard/certificateWizard.xhtml @35,67 value="#{flowScope.firstName}": Target Unreachable, identifier 'flowScope' resolved to null

Here is my code:

<h:outputLabel value="First Name" for="firstname" styleClass="control-label col-md-2" />
    <div class="control col-md-4">
        <h:inputText id="firstname" value="#{flowScope.firstName}" class="form-control" required="true">
            <f:passThroughAttribute name="placeHolder" value="First Name"/>
        </h:inputText>
    </div>
</h:outputLabel>

This is my flow configuration in faces-config.xml file:

<flow-definition id="certificateWizard">
    <flow-return id="flowReturn">
        <from-outcome>protected/pages/index.xhtml</from-outcome>
    </flow-return>
</flow-definition>`
unleashed
  • 331
  • 1
  • 5
  • 17
  • There is no enough information. Post the code of your managed bean too. – Diogo Calazans Aug 12 '14 at 16:21
  • isn't flowScope independent of a Managed Bean since it is an implicit object? I have no managed bean code as yet. – unleashed Aug 12 '14 at 22:05
  • you are right @unleashed, my bad.Could you post your flow configuration? Are you using tomcat?Maybe this link may help you: [config tomcat to use cdi](http://balusc.blogspot.de/2013/10/how-to-install-cdi-in-tomcat.html) – Diogo Calazans Aug 13 '14 at 12:03
  • I am using glassfish. I have included the flow configuration above – unleashed Aug 13 '14 at 14:13

1 Answers1

1

I have solved the problem. The folder that has the flow web pages has to be placed directly in the context root and not as the subfolder of another folder.

unleashed
  • 331
  • 1
  • 5
  • 17