First of all, the "id" attribute MUST be unique within its container and I'm not sure how you even get the page to compile otherwise. That's a basic restriction that's part of JSF's XML heritage.
lynn fann wrote:
I cant use "required=true", as i have 2 section for the user to chose to enter. The user just need to enter either sections. Within the section, there are serveral field that are mandatory. and why i did a validation check for null values in my managed bean is because the validator will not be invoked if it is a blank field.
Have another question, when i set the required=true on readonly field, it doesnt work, why is this so? Is this just how jsf set it?
"Required" means INPUT required, so putting it on a display-only control is sort of a contradiction in terms. Although I seem to remember having the same problem once.