Joe Hesse wrote:
> Hi,
>
> I have two complete html files below.
> The first one has an inline style in the <body> element.
> The second one has an inline style in the <div> element.
> Otherwise, the files are the same.
>
> When the first file is viewed with a browser both the paragraph and
> table are red. When the second file is viewed with a browser only the
> paragaph is red. I expected that both the paragraph and table would
> display as red in the second file since the <div> element encloses both
> of them.
>
> I have used Firefox, Mozilla, and IE, all with the same results.
>
> Please help.
>
> Thank you,
> Joe Hesse
>
> ----- demo1.htm -----
> <html><head></head>
>
> <body style="color:red">
>
> <div>
>
> <p>Some Text</p>
>
> <table border="2">
> <tr><td>Dog</td><td>Carrot</td></tr>
> <tr><td>Cat</td><td>Spinach</td></tr>
> </table>
>
> </div>
>
> </body></html>
>
> ----- demo2.htm -----
> <html><head></head>
>
> <body>
>
> <div style="color:red">
>
> <p>Some Text</p>
>
> <table border="2">
> <tr><td>Dog</td><td>Carrot</td></tr>
> <tr><td>Cat</td><td>Spinach</td></tr>
> </table>
>
> </div>
>
> </body></html>
>
>
Both files look the same to me. Paragraph and table are red in both
files.
Run this in IE, Firefox and Opera.
Don't see the problem, so cant help you mate.
Ed.


|