T O P I C R E V I E W |
AnonJr |
Posted - 07 March 2009 : 17:48:31 I'm working on a Snitz forum, but I want to simplify some of the styling on the various tables. Silly me figured I'd use some standard thing like <col> and <colgroup> but guess which browser is the only one that doesn't fully implement the standard!
Some research has turned up that its a problem with the Gecko rendering engine, and its one of the older standing bugs.
I just needed to vent. |
7 L A T E S T R E P L I E S (Newest First) |
HuwR |
Posted - 08 March 2009 : 11:29:51 ok, got ya
you should be able to use CCS though, something like this should set the second col to align center.
td:first-child+td{text-align:center;}
|
AnonJr |
Posted - 08 March 2009 : 10:37:44 I see - we're both talking about alignment, but you're talking using CSS's align property, and I'm talking about the good ole "<col align="whatever" />" - which (last I checked) is listed as kosher at www.w3c.org.
And again, its not just IE that supports it - I mentioned IE as the more ironic browser supporting it. You'd think if it wasn't right the standard zanies over at Opera wouldn't support it either.
Edit: I should add that I'll go back and look closer at the other styles I'm trying to apply. I could have sworn that it was supposed to be that way... |
HuwR |
Posted - 08 March 2009 : 10:07:42 alignment is NOT part of the CSS2 spec for COL it supports border,width, backcground and visibility.
quote:
17.3 Column selectors Table cells may belong to two contexts: rows and columns. However, in the source document cells are descendants of rows, never of columns. Nevertheless, some aspects of cells can be influenced by setting properties on columns.
The following properties apply to column and column-group elements:
'border' The various border properties apply to columns only if 'border-collapse' is set to 'collapse' on the table element. In that case, borders set on columns and column groups are input to the conflict resolution algorithm that selects the border styles at every cell edge. 'background' The background properties set the background for cells in the column, but only if both the cell and row have transparent backgrounds. See "Table layers and transparency." 'width' The 'width' property gives the minimum width for the column. 'visibility' If the 'visibility' of a column is set to 'collapse', none of the cells in the column are rendered, and cells that span into other columns are clipped. In addition, the width of the table is diminished by the width the column would have taken up. See "Dynamic effects" below. Other values for 'visibility' have no effect.
Here are some examples of style rules that set properties on columns. The first two rules together implement the "rules" attribute of HTML 4.0 with a value of "cols". The third rule makes the "totals" column blue, the final two rules shows how to make a column a fixed size, by using the fixed layout algorithm.
COL { border-style: none solid } TABLE { border-style: hidden } COL.totals { background: blue } TABLE { table-layout: fixed } COL.totals { width: 5em }
quote: Gecko is the only rendering engine that doesn't fully support styling (I can change the background but not the text color - WTF?)
That is as per the spec, so no problem their it is IE that is wrong in allowing it not FF for not allowing it, this is why we have a browser problem with the WWW because some browsers allow you to do things that are not part of the standard. |
AnonJr |
Posted - 08 March 2009 : 09:47:44 Last I checked align was a part of the spec... but anyway, Gecko is the only rendering engine that doesn't fully support styling (I can change the background but not the text color - WTF?), alignment, and a few other items. Opera handles it like a champ. IE handles it fine. Safari/Chrome works great too. Just Fx has problems. Though to be fair, it seems to be the Gecko engine in particular.
Anyway, I'm trying to set the column's alignment and some other styling without having to repeat the code over each <td>. That way if I change my mind its a lot easier to fix it later. |
HuwR |
Posted - 08 March 2009 : 04:09:40 as far as I am aware FF supports the col/colgroup standard just fine, what eactly were you trying to achieve ?
just because something works in IE doesn't allways mean that it is following standards, the biggest difference between IE and all the other browsers is that it lets you get away with stuff that isn't standards compliant
most of the stuff I have read where people were having problems with FF were when trying to use align, IE supports align for COL, but it is not in the HTML spec so FF does not support it. It is a huge debate as to whch is correct, but to standards it is FF that is correct in not implementing align, and IE that is wrong. |
AnonJr |
Posted - 07 March 2009 : 21:01:31 What kills me is that it works fine in the much maligned IE. |
JJenson |
Posted - 07 March 2009 : 20:55:49 Seems like no browser is perfect.
I hate browser bugs more than anything else in this industry lol. |
|
|