Pixel Pete saysXHTML pages declare a DOCTYPE that names the exact DTD version they follow.
An XHTML 1.0 page opens with a long <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "…dtd"> that points at a Document Type Definition. The DTD defines which elements and attributes are legal. This verbose doctype is one of XHTML's signatures — and a relief that HTML5 simplified it to just <!doctype html>.
Power-ups you unlock
Long DOCTYPE names the DTD version
DTD defines legal elements/attributes
Strict, Transitional, or Frameset variants
HTML5 simplified it to <!doctype html>
Quirks Mode attacks — common mistakes
Omitting the doctype (parser falls back)
Copying the wrong DTD variant
Assuming the HTML5 short doctype works for strict XHTML
Boss battleIdentify the parts of an XHTML 1.0 Strict doctype line.
Example code
<?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" xml:lang="en">
<head><title>xhtml doctype</title>
<style type="text/css">body{background:#06040d;color:#e6e0ff;font-family:monospace;padding:20px}</style>
</head><body><p>this page declares an XHTML 1.0 Strict doctype.</p></body></html>