For a recent project I spend a lot of time trying to dynamically
hide/show columns in an HTML table using styles and had no success at
all. It seems that HTML simply does not support this at all.
Note that this is *not* a JSF issue; JSF can use "rendered" to suppress
a column. However as in Oliver's case, I wanted the column to be present
in the HTML page, just invisible (so that javascript could be used to
toggle the column visibility). It seems logical that visibility:hidden
or display:none should do this, but neither affects the column header
(TH tag) in the expected manner - at least I couldn't find any style
option that would do so.
Eventually I gave up.
Regards,
Simon
Pfau, Oliver wrote:
When I set "visibility: hidden" on the t:column, the content of the column (checkbox in my case) is not visible, but the column is drawn empty. I want to keep the checkbox (for some javascript stuff) but hide the complete column.
-----Ursprüngliche Nachricht-----
Von: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Im Auftrag von Matthias
Wessendorf
Gesendet: Freitag, 2. Februar 2007 12:51
An: MyFaces Discussion
Betreff: Re: Visibility of t:column
Oliver,
what is the rendered output?
Can you try to play with firebug and manipulate the *dom* to get the
"hidden" result?
Thanks,
Matthias
On 2/2/07, Pfau, Oliver <[EMAIL PROTECTED]> wrote:
Hi,
how can I hide a complete column of t:dataTable ? I tried style="visibility:
hidden" with no success. It should not be rendered="false".
Regards,
Oliver