I am trying to craete a JSF page. I want to get the user input either from a drop down list or input text field
If the user starts typing in "input text" then the drop down list should be disabled. Otherwise if the user selects a name from the drop down list, then input text filed should be disabled. I tried as follows. But it doesn't work properly. Can anyone give me some suggestion?
What you are describing closely resembles a ComboBox control, except that a traditional ComboBox doesn't actually disable the list, since typing can be used to more rapidly locate an entry in the list. A variation of this for Web 2.0 is to use AJAX to cause the list to dynamically adjust itself based on what has already been typed.
The secret of how to be miserable is to constantly expect things are going to happen the way that they are "supposed" to happen.
You can have faith, which carries the understanding that you may be disappointed. Then there's being a willfully-blind idiot, which virtually guarantees it.
See where your hand is? Not there. It's next to this tiny ad:
a bit of art, as a gift, that will fit in a stocking