Editing Border Of One Side In A Cell Without Css, Only With Html/xhtml?
Say I have a table that looks like this: http://www.w3schools.com/html/tryit.asp?filename=tryhtml_table_collapse Is it possible to remove/edit cells of a border without CSS, and on
Solution 1:
This answer revolves around section 11.3.1 of the HTML401 specification; this uses data which isn't present in the HTML5 specification.
HTML offers some support for borders through the frame
and rules
attributes. These affect entire columns or rows, but not individual cells. You cannot use these to apply a border to only one cell, but you can use this to apply a border to a row or column.
For example, setting frame="rhs"
(right hand side) and rules="all"
on the table
element will render the border like this (JSFiddle demo):
1 | 2 | 3 |
| | |
Values the frame
attribute supports:
void: No sides. This is the default value.
above: The top side only.
below: The bottom side only.
hsides: The top and bottom sides only.
vsides: The right and left sides only.
lhs: The left-hand side only.
rhs: The right-hand side only.
box: All four sides.
border: All four sides.
Values the rules
attribute supports:
none: No rules. This is the default value.
groups: Rules will appear between row groups...
rows: Rules will appear between rows only.
cols: Rules will appear between columns only.
all: Rules will appear between all rows and columns.
Post a Comment for "Editing Border Of One Side In A Cell Without Css, Only With Html/xhtml?"