Elements express content roles

Elements identify roles such as headings, paragraphs, lists and links. Attributes add information including language and destinations; an a element’s href supplies the target reference.

The markup does not freeze a page into an image. Its structural roles can be interpreted across screens and assistive tools; merely enlarging arbitrary text does not give it heading semantics.

Forms also have structural semantics: native submission constructs name–value entries rather than sending every visible word. Disabled controls and unchecked checkboxes are skipped, and an ordinary text input without a nonempty name supplies no corresponding entry. A label identifies a control without replacing its submission name, so visually similar forms can submit different data when their attributes differ.

References: [1] [3]

Markup and the in-memory tree

A browser parses HTML syntax into a DOM containing element and text nodes. That runtime representation is not an unchanged copy of the source string and can be modified by scripts.

HTML and XML have distinct parsing requirements. Void elements such as img and input do not take end tags, while some other tags can be omitted under specific rules; XML conventions cannot simply be applied wholesale.

References: [1] [2]

Structure, presentation and transfer

HTML concentrates on document structure and related semantics. CSS can control presentation, scripts can cooperate with platform APIs, and HTTP exchanges requests and responses for resources.

It is therefore neither a complete website application nor a requirement for dynamic generation. Static files and server-produced responses can use the same syntax; scripting and databases depend on the application.

References: [1]