HTML Tables Don't Inherit Styles Properly

Background

Early browser CSS bugs caused tables to not properly inherit styles from their parent objects. For example, a table tag in a div tag would not receive the color or font-size styles from the div.

The Problem

Even though modern browsers are now perfectly capable of proper CSS support, including table style inheritance, they will not do so unless instructed. They do this to keep from breaking all of the old websites that conformed to the bad old browsers.

The Solution

To tell your browser that you are writing modern HTML or XHTML that deserves to be treated as such, you will want to label your page(s) with a 'strict' DOCTYPE. Here is an HTML example which goes before your <html> tag.:

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"
 "http://www.w3.org/TR/html4/strict.dtd">

XHTML needs a few other items, so here is an example for that:

<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
        "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">

For more DOCTYPES and more information on the subject, here is an official W3C article on the subject: http://www.w3.org/QA/2002/04/valid-dtd-list.html.