-
1. Re: Class 'dr-table' prevents cellspacing and cellpadding
amitev Aug 2, 2007 8:20 AM (in response to amitev)The problem appears on firefox and comes from "border-collapse: collapse;"
-
2. Re: Class 'dr-table' prevents cellspacing and cellpadding
sergeysmirnov Aug 2, 2007 12:43 PM (in response to amitev)Add to the style sheet:
.rich-table { border-collapse:inherit; }
-
3. Re: Class 'dr-table' prevents cellspacing and cellpadding
sergeysmirnov Aug 2, 2007 12:45 PM (in response to amitev)If you want to do it only for one particular table, define the same in its style or styleClass
-
4. Re: Class 'dr-table' prevents cellspacing and cellpadding
amitev Aug 2, 2007 3:18 PM (in response to amitev)Thank you Sergey! As as i see in the rendered html each element in grid got style that contains border 1px. Is there an "easy" way to remove the border fr omthe grid.
-
5. Re: Class 'dr-table' prevents cellspacing and cellpadding
sergeysmirnov Aug 2, 2007 3:54 PM (in response to amitev)do you know the way how to set the width of the pure html table with css defining it only one place?
-
6. Re: Class 'dr-table' prevents cellspacing and cellpadding
amitev Aug 2, 2007 6:52 PM (in response to amitev)<table style="width: 200px" >..
? -
7. Re: Class 'dr-table' prevents cellspacing and cellpadding
sergeysmirnov Aug 2, 2007 7:08 PM (in response to amitev)I mean the width of the border, because you are asking about the border.
-
8. Re: Class 'dr-table' prevents cellspacing and cellpadding
amitev Aug 2, 2007 7:18 PM (in response to amitev)Yes. It's applied on each cell - this is how the component is rendered. I don't see a way to do it only once.
-
9. Re: Class 'dr-table' prevents cellspacing and cellpadding
sergeysmirnov Aug 2, 2007 7:52 PM (in response to amitev)Right. This is a point. The difference between html table and rich:dataTable is a default value for border width. richFaces has 1px. To makes this 0px, you need to defines styles for table cells also.
Actually, rich:dataTable has more complicated structure than h:dataTable (which is similar to html table). It has cells, header cells, footer cell, subtable, subtable cells, subtable header cell, subtable footer cells and so on.
Of cause, it you do not use all of then, you do not have to have so definitions for styles also.
This is what makes the table of livedemo (that has almost everything) borderless:.rich-table, .rich-table-header,.rich-table-headercell, .rich-table-cell, .rich-subtable-cell, .rich-table-footercell, .rich-subtable-footercell { border-width:0px; }
Just in case, this removes the backgrounds:.rich-table, .rich-table-header, .rich-table-header-continue, .rich-table-footer, .rich-subtable-footer { background-image:none; background-color:transparent; }