HTML and CSS Reference
In-Depth Information
table {
width: 90%;
margin: 0 auto;
font-family: Lucida Grande, Verdana, Helvetica, Arial, sans-serif;
font-size: .9em;
line-height: 1.4em;
border-collapse: collapse;
}
tr {
border: 1px solid #666;
}
th {
text-align: left;
border-left: 1px solid #333;
border-right: 1px solid #333;
border-bottom: 3px double #333;
padding: 0 .5em;
}
td {
color: #333;
border: 1px dotted #666;
padding: 0 .5em;
}
Adding these styles to our CSS gives us the result shown in Figure 10-7.
Figure 10-7. Adding some basic border styles to our sample table
As you can see, there are countless ways to use borders with tables. Throughout the chap-
ter, the examples will use different borders to show more possibilities.
Search WWH ::




Custom Search