Download presentation
Presentation is loading. Please wait.
Published byConstance Barnett Modified over 9 years ago
1
XHTML is aimed to replace HTML XHTML is almost identical to HTML 4.01 XHTML is a stricter and cleaner version of HTML XHTML is HTML defined as an XML application
2
The rules for writing XHTML documents are: All tag and attribute names must be in lowercase "Empty" tags must be written with an extra slash at the end You can never omit an end tag Attributes must always have a value Attributes values must always be quoted
3
LEGACY HTML... XHTML...
4
LEGACY HTML XHTML
5
LEGACY HTML..... paragraph text..... more paragraph text XHTML..... paragraph text..... more paragraph text
6
LEGACY HTML XHTML
7
LEGACY HTML XHTML
8
XHTML elements must be properly nested, be closed, be in lowercase, and be nested within the root element Attribute names must be in lower case, values must be quoted The id attribute replaces the name attribute The XHTML DTD defines mandatory elements All XHTML documents must have a DOCTYPE declaration. The html, head, title, and body elements must be present
9
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> simple document a simple paragraph
10
An XHTML DTD describes in precise, computer-readable language, the allowed syntax and grammar of XHTML markup Strict Use this when you want clean markup, free of presentational clutter. Use this together with CSS. Transitional Use this when you need to take advantage of HTML's presentational features and when you want to support browsers that don't understand CSS. Frameset Use this when you want to use HTML Frames to partition the browser window into two or more frames.
Similar presentations
© 2024 SlidePlayer.com. Inc.
All rights reserved.