From: Jason Yundt Date: Thu, 2 Jun 2022 11:43:05 +0000 (-0400) Subject: gitweb: switch to an XHTML5 DOCTYPE X-Git-Url: https://git.ladys.computer/Gitweb/commitdiff_plain/6745a06c525fbf2f19fa3a653269b3dad2f5d8ac0ceb81b2790a36cd7015d93f?ds=sidebyside;hp=6745a06c525fbf2f19fa3a653269b3dad2f5d8ac0ceb81b2790a36cd7015d93f gitweb: switch to an XHTML5 DOCTYPE According to the HTML Standard FAQ: “What is the DOCTYPE for modern HTML documents? In text/html documents: In documents delivered with an XML media type: no DOCTYPE is required and its use is generally unnecessary. However, you may use one if you want (see the following question). Note that the above is well-formed XML.” Source: [1] Gitweb uses an XHTML 1.0 DOCTYPE: While that DOCTYPE is still valid [2], it has several disadvantages: 1. It’s misleading. If an XML parser uses the DTD at the given link, then the entities   and ⋅ won’t get declared. Instead, the parser has to use a DTD from the HTML Standard that has nothing to do with XHTML 1.0 [2]. 2. It’s obsolete. XHTML 1.0 was last revised in 2002 and was superseded in 2018 [3]. 3. It’s unreliable. Gitweb uses   and ⋅ but lets an external file define them. “[…U]using entity references for characters in XML documents is unsafe if they are defined in an external file (except for <, >, &, ", and ').” [4] [1]: [2]: [3]: [4]: Signed-off-by: Jason Yundt Signed-off-by: Junio C Hamano ---