Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6604373
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T19:08:48+00:00 2026-05-25T19:08:48+00:00

Good morning! I am novice. I have a simple JSF application. But it does

  • 0

Good morning! I am novice. I have a simple JSF application. But it does not work as expected.
This is my login.xhtml:

<h:body>
    <h:outputText value="Please enter your login and password"/>
    <h:form id="loginForm">
        <h:panelGrid columns="2">       
                <h:outputText value="User name"/>                   
                <h:inputText value="#{textBean.login}" required="true"/>
                <h:outputText value="Password"/>
                <h:inputSecret value="#{textBean.password}" required="true"/>
                <h:commandButton value="Submit" action="#{textBean.doLogin}"/>
        </h:panelGrid> 
    </h:form>
</h:body>

This is my error.xhtml:

<h:body>
    <h:outputText value="You have entered incorrect data"/>
    <h:form id="errorForm">    
                <h:commandLink value="Back to login page" action="#{TextBean.backToLogin}"/>
    </h:form>
</h:body>

This is my bean class TextBean.java:

public class TextBean implements Serializable {

private static final long serialVersionUID = 1L;

private String login;

private String password;

public String getLogin() {
    return login;
}

public void setLogin(String login) {
    this.login = login;
}

public String getPassword() {
    return password;
}

public void setPassword(String password) {
    this.password = password;
}

public String doLogin() {
    if ("admin".equals(login) && "mypass".equals(password)) {
        return "welcome";
    } else {
        return "error";
    }

}

public String backToLogin() {
        return "login";
}

}

Why the error page does not go back to the login page? When you click on the link “Back to login page” I get the exception. What am I doing wrong?
This is my exception:

        The server encountered an internal error () that prevented it from fulfilling this request.
javax.servlet.ServletException: javax.el.PropertyNotFoundException: /error.xhtml @14,80 action="#{TextBean.doMyLogin}": Target Unreachable, identifier 'TextBean' resolved to null
    javax.faces.webapp.FacesServlet.service(FacesServlet.java:521)
javax.faces.el.EvaluationException: javax.el.PropertyNotFoundException: /error.xhtml @14,80 action="#{TextBean.doMyLogin}": Target Unreachable, identifier 'TextBean' resolved to null
    javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:95)
    com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
    javax.faces.component.UICommand.broadcast(UICommand.java:315)
    javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:787)
    javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:1252)
    com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:81)
    com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101)
    com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
    javax.faces.webapp.FacesServlet.service(FacesServlet.java:508)
javax.el.PropertyNotFoundException: /error.xhtml @14,80 action="#{TextBean.doMyLogin}": Target Unreachable, identifier 'TextBean' resolved to null
    com.sun.faces.facelets.el.TagMethodExpression.invoke(TagMethodExpression.java:107)
        javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
    com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
    javax.faces.component.UICommand.broadcast(UICommand.java:315)
    javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:787)
    javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:1252)
    com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:81)
    com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101)
    com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
    javax.faces.webapp.FacesServlet.service(FacesServlet.java:508)

Help me please, dear friends! Any help would be greatly appreciated.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-25T19:08:49+00:00Added an answer on May 25, 2026 at 7:08 pm

    The name of your bean is textBean not TextBean. That is why JSF can’t resolve it: identifier 'TextBean' resolved to null

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Good morning. I've been having this issue for some days and have been lokking
Good morning. Take this simple scenario: I've got a NetClient that connects itself to
Good morning in my timezone. Those are simple questions , i just do not
Good Morning, I have copied this code from somewere <script type=text/javascript> $(function() { setInterval(rotateImages(),
Good morning! We have a SVN-Repository, which holds a VS-Solution. In this solution are
Good morning, I have to use the properties from DeviceNetworkInformation in my application. (http://msdn.microsoft.com/en-us/library/microsoft.phone.net.networkinformation.devicenetworkinformation(v=vs.92).aspx)
good morning programers, I have this small code which content a news control panel
Good Morning, I have an application which allows users to slide values for different
Good morning, I have mysql queries where I would like to calculate percentage of
Good morning, I am currently developing a java web application that exposes a web

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.