Meaningless Drivel is fun!
The moose likes HTML, CSS and JavaScript and the fly likes HTML DOCType problem Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "HTML DOCType problem" Watch "HTML DOCType problem" New topic

HTML DOCType problem

vanlalhmangaiha khiangte
Ranch Hand

Joined: Sep 11, 2006
Posts: 170
I am currently reading the tutorial HTML Doctype
HTML 4.01 Strict
This DTD contains all HTML elements and attributes, but does NOT INCLUDE presentational or deprecated elements (like font and center). Framesets are not allowed:

I am trying to use Strict doctype as below but the frameset is still showing.

Can you please guide me how to use each doctype properly with an example

Bear Bibeault
Author and ninkuma

Joined: Jan 10, 2002
Posts: 63844

Why bother with all that mess? Just use the HTML5 doctype of:

<!DOCTYPE html>

and write to modern standards.

[Asking smart questions] [About Bear] [Books by Bear]
Paul Clapham

Joined: Oct 14, 2005
Posts: 19973

vanlalhmangaiha khiangte wrote:I am trying to use Strict doctype as below but the frameset is still showing.

Well, your HTML document may well be invalid because it doesn't conform to its DTD. However browsers don't require well-formed and valid HTML, they will make their best effort to make some sense of even the worst example of tag soup. In your case I expect the browsers would just ignore the DTD and carry on with the HTML which they see.
I agree. Here's the link:
subject: HTML DOCType problem
It's not a secret anymore!