Previous Message
Next Message

Applying A Border To <tr>

Sent by cj on 22 March 2006 19:07

On 3/22/06, Zoe M. Gillenwater [EMAIL-REMOVED]> wrote:
> Michael Warkentin wrote:
> > I'm having an issue with styling a table.  Everything is working great, but
> > when I try to apply a border to the <tr> elements, nothing shows up.  If I
> > view the element in the IE DOM inspector, it shows that there should be a
> > border.  I don't have access to an outside server to put up my example, but
> > the relevent code is below.  If you need anything else, let me know..
> >
> You need to apply the borders to the td or th elements in the tr's, not
> the tr's themselves.

in case this helps, you can still give the tr a class, such as
"my-tr-class" and then do:

/* to give a top or bottom border to this "tr" */ td {border-top: 1px solid black;}

or alternatively:
/* to give every cell in the table a border without gaps */
table {border-collapse: collapse;}
td {border: 1px solid black;}
css-discuss [EMAIL-REMOVED]]
IE7b2 testing hub --
List wiki/FAQ --
Supported by --
Previous Message
Next Message

Message thread: