White Space Characters Handling Rules in HTML

Q

How Exactly White Space Characters Are Ignored?

✍: FYIcenter.com

A

White space characters will be processed (ignored) based where they are located:

  • White space characters will be ignored between block elements.
  • White space characters will be preserved in element "pre".
  • White space characters will be preserved in CDATA.
  • Multiple consecutive white space characters will be replaced by a single space character in PCDATA.
  • White space characters will be ignored in EMPTY content elements.

 

Getting Extra White Spaces in HTML

White Space Characters in HTML

Introduction of HTML Element Content Syntax

⇑⇑ HTML Tutorials

2024-02-21, 1429🔥, 2💬