Hi,
Thank you, that's exactly the piece of information I was missing.
Regards,
Steph
Dennis Byrne wrote:
The value of @columns needs to = the # immediate children .
If you want two tags to be in the same cell, wrap them w/ a
panelGroup or panelGrid.
---- Original message ----
Date: Thu, 08 Sep 2005 11:59:03 -0400
From: Stephane Grenier <[EMAIL PROTECTED]>
Subject: error messages in panelgrids
To: users@myfaces.apache.org
Hello,
I'm having some problems trying to understand how to
properly layout the
code. What I'm trying to do is use a panelgrid, one column
for the
label, one for the input, and potentially one for the error
message if
required. However, I can't seem to get to display correctly.
Some sample
code:
<h:panelGrid columns="3">
<h:outputText value="Id:">
<h:inputText id="id" value="#{myForm.id}"/>
<h:outputText value="Another ID:"/>
<h:inputText id="anotherId" value="#
{myForm.anotherId}">
<f:validateLength minimum="1" maximum="1" />
</h:inputText>
<h:message style="color: red;" id="idError"
for="anotherId"/>
</h:panelGrid>
Here are the issues I have. Firsly, because columns=3 in the
panel grid
definition, the first row has the "Another ID" text as the
last column.
Then to solve this I put columns=2 but now when there is a
validation
error on the second row, the error message appears as a
third row.
Your suggestions would be appreciated.
Regards,
Steph
Dennis Byrne