vertically aligning the contents of a panelgrid
843842Feb 23 2005 — edited Sep 30 2007Hello,
Does anyone know how to vertically align the contents of a PanelGrid? For example, using HTML, you can do the following:
<table cellSpacing="10" cellPadding="10" border="1" bgcolor="#AAAAAA">
<tr>
<td>1</td>
<td>2</td>
<td rowspan="2" valign="top">3</td>
</tr>
<tr>
<td>4</td>
<td>5</td>
</tr>
</table>
which will position '3' at the top of the cell. However, trying something like this in JSF, i.e.:
<h:panelGrid style="valign:top;height=200;text-align:center">
<h:outputLabel value="3" />
</h:panelGrid>
does not work (interestingly, the 'text-align:center' portion does work). That is, '3' still appears centered in the panel.
Does anyone know how to get the PanelGrid to position '3' at the top?
Thanks!
Robert