Posted by JimO on 10/16/63 11:17
If DTDs are supposed to enforce syntax rules, then why if I have the
following DTD the html underneath works?
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<b><i>italics bold</b></i>
<img src="images/bacon.jpg">
The first line should be
<b><i>italics bold</i></b>
The second line should be
<img src="images/bacon.jpg" />
Shouldn't I get an error message or the code just won't work?
[Back to original message]
|