About this format
XHTML applies strict XML formatting rules to HTML, ensuring tags are perfectly balanced, closed, and lowercase.
Example Data
<?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">
<head>
<title>XHTML Example</title>
</head>
<body>
<h1>Strict XML Parsing</h1>
<p>Every tag must be <strong>properly closed</strong>.</p>
<br />
</body>
</html>When to use XHTML Document
- Guaranteeing document structure validity
- Parsing web pages with standard XML parsers
- Legacy web development