Questions tagged [colgroup]

Relating to HTML, the colgroup represents a group of columns in an HTML table.

Description

In HTML - <colgroup> element defines a group of columns within a table and allows to set attributes that might otherwise have to be set at <col> level on a number of col elements simultaneously — the attributes defined at this higher level apply to all of the child columns.

References

  1. W3C Specification
  2. colgroup - MDN Link
35 questions
24
votes
2 answers

Should I use and , and if so, why and how?

I've been trying to use properly the colgroup and the col tags but I don't get it. I read the specification and all that but I don't understand its purpose or how to implement it.
Roger G. Zapata
  • 361
  • 1
  • 3
  • 10
8
votes
3 answers

CSS col visibility:collapse does not work on Chrome

I'm trying to hide some col's in html code. Using MDN colgroup and col are added, and I'm playing with the style of the cols. The with content text 'visible' is visible in all browsers (good), the with content text 'hidden' is visible in…
Guy Dafny
  • 1,709
  • 1
  • 14
  • 25
8
votes
4 answers

How to center XHTML (and/or HTML4) TABLE columns by colgroup?

How to align all columns by colgroup? It works with colspan? Example This HTML here was tested with Firefox and Chrome, but no browser renderize the center for all expected columns.
Peter Krauss
  • 13,174
  • 24
  • 167
  • 304
6
votes
0 answers

How does position: absolute; and the colgroup tag work together?

My final goal is to create a table that has a first column that remains in place, but the other columns horizontally scroll. I have found some other solutions, but am curious as to why colgroup and absolute do not seem to work…
notthehoff
  • 1,172
  • 1
  • 12
  • 28
6
votes
2 answers

Add spacing between to colgroups

I have an HTML table with a few colgroups that I put a border around. I would like to add some space between adjacent groups. Is there a way to do this in CSS without adding empty cells between groups?
Dave
  • 1,196
  • 15
  • 22
5
votes
1 answer
columns leave visible artifacts behind
According to the documentation we can use visibility: collapse on a
element to collapse or fold all associated columns. But (in Chrome and Edge) I noticed that some elements remain visible, floating somewhere along the area that the…
Martin
  • 5,714
  • 2
  • 21
  • 41
4
votes
2 answers

Span attribute on colgroup and col

Are these codes logically equivalent?
And And Will any attributes via HTML or properties via CSS have equal effect?…
Jawad
  • 8,352
  • 10
  • 40
  • 45
4
votes
1 answer
/ HTML tags to alter and rows?
Is there a way to limit/restrain the field of "operation" of styles defined in
/ HTML tags. Given the following table:
CDuv
  • 2,098
  • 3
  • 22
  • 28
3
votes
3 answers
lorem lorem
and my styles are: col.selected…
Marcin
  • 5,469
  • 15
  • 55
  • 69
3
votes
1 answer

java xml parser Exception: The end-tag for element type "col" must end with a '>' delimiter

I want to parse some Html string to org.w3c.dom.Document, I use this method: public static Document stringToDocument(String input){ try { DocumentBuilder db = DocumentBuilderFactory.newInstance().newDocumentBuilder(); …
MTB
  • 405
  • 1
  • 5
  • 12
3
votes
1 answer

Colgroup tag in code but missing from view source or debugger tool

This is sort of the opposite of this question Why does firebug add to ? and may end up being the same answer but I want to confirm. I have a colgroup in my code that, when I use Firebug or IE debugging tools, it just vanishes. See the…
Justin williams
  • 574
  • 1
  • 8
  • 26
tag?
I am having trouble using the < colgroup > tag to style the borders of a table column in CSS. Here is the code I am trying to run:
puzzleGuzzle
  • 101
  • 10
2
votes
1 answer

Aligning text in table column group in HTML5

I am trying to align (center) content in group of a columns in my table. I've learned about colgroup and col elements (never used them before). I've learned that those elements had align attribute, but now, in HTML, it's gone. On w3school service…
Soul Reaver
  • 2,012
  • 3
  • 37
  • 52
2
votes
1 answer

How to fit a table into Susy grid?

I'm trying to figure out how to fit a
into a Susy grid. Meaning a elements to the width returned by Susy's space() function.…
Niels
  • 372
  • 2
  • 15
1
vote
1 answer

Table colgroup col style inconsistency with colspan

I am trying to highlight a column with cells that use the span attribute, like a overarching header cell. I tried it in the most obvious way by using the colgroup and col tag. Unfortunately, this delivers inconsistent results. An overarching cell…
Daniel
  • 3,383
  • 4
  • 30
  • 61
1
2 3
or a should be as wide as a Susy grid column or a number of Susy grid columns. My idea is to set the