aspose file tools
The moose likes JSF and the fly likes Problem with attributes  backing bean Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Java » JSF
Reply Bookmark "Problem with attributes  backing bean " Watch "Problem with attributes  backing bean " New topic
Author

Problem with attributes backing bean

cesar vasde
Greenhorn

Joined: Jan 01, 2011
Posts: 15
You see, I have the following exceptions


This is the bean



faces-config.xml



The values that print in console are:

user: null
pass: null

As you can see, the fields of backing bean are null even though the xhtml page I put some value on them


What do you think is the problem?

Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 14456
    
    7

You are getting the NullPointerException because you are attempting to invoke the equals() method on something that you already know is a null string (since you just printed it).

Normally, I'd expect the fields to be set to empty strings as part of the JSF request process, but you didn't include the actual page definition, so I can't tell whether you have your page form setup properly.

Aside from that, the technical name for "user-defined login" is Security Hole.


Customer surveys are for companies who didn't pay proper attention to begin with.
naveen gupta
Ranch Hand

Joined: Apr 12, 2006
Posts: 129
The values you are entering in the GUI are not getting stored in the variables you defined in the backing bean
Put up some log statements and work in that direction to see why the values are not getting entered in the variables of JSF backing bean
best of luck
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Problem with attributes backing bean
 
Similar Threads
[JBoss 6.0.0 M2 (soon)] EJB 3.1 and JSF : NoInterfaceProxy error
How to Reterive Row Data in JSF
Blank page on backing bean exception
javax.el.PropertyNotFoundException: Objetivo inalcanzable - JSF - Facelet - method-signature
JSF managed bean not created error