Skip to content

Instantly share code, notes, and snippets.

@nireno
Last active September 1, 2022 23:07
Show Gist options
  • Save nireno/39b1c81e79b8e037c8f2e02ecc024527 to your computer and use it in GitHub Desktop.
Save nireno/39b1c81e79b8e037c8f2e02ecc024527 to your computer and use it in GitHub Desktop.
Boilerplate html useful for testing css styles against common rich text editor markup
<h1>HyperText Markup Language</h1>
<p>The HyperText Markup Language, or HTML is the standard markup language for documents designed to be displayed in a web browser. It can be assisted by technologies such as Cascading Style Sheets (CSS) and scripting languages such as JavaScript.</p>
<h2>History</h2>
<h3>Development</h3>
<img class="alignleft" src="https://upload.wikimedia.org/wikipedia/commons/thumb/c/c8/Tim_Berners-Lee_April_2009.jpg/340px-Tim_Berners-Lee_April_2009.jpg" />
<p>In 1980, physicist Tim Berners-Lee, a contractor at CERN, proposed and prototyped ENQUIRE, a system for CERN researchers to use and share documents. In 1989, Berners-Lee wrote a memo proposing an Internet-based hypertext system.[3] Berners-Lee specified HTML and wrote the browser and server software in late 1990. That year, Berners-Lee and CERN data systems engineer Robert Cailliau collaborated on a joint request for funding, but the project was not formally adopted by CERN. In his personal notes[4] from 1990 he listed[5] "some of the many areas in which hypertext is used" and put an encyclopedia first.</p>
<h3>HTML versions timeline</h3>
<h4>HTML 2</h4>
<p>HTML 2.0 was published as RFC 1866. Supplemental RFCs added capabilities:</p>
<ul>
<li>November 25, 1995: RFC 1867 (form-based file upload)</li>
<li>May 1996: RFC 1942 (tables)</li>
<li>August 1996: RFC 1980 (client-side image maps)</li>
</ul>
<h3>SGML-based versus XML-based HTML</h3>
<p>To understand the subtle differences between HTML and XHTML, consider the transformation of a valid and well-formed XHTML 1.0 document that adheres to Appendix C (see below) into a valid HTML 4.01 document. To make this translation requires the following steps:</p>
<ol>
<li>The language for an element should be specified with a lang attribute rather than the XHTML xml:lang attribute. XHTML uses XML's built in language-defining functionality attribute.</li>
<li>Remove the XML namespace (xmlns=URI). HTML has no facilities for namespaces.Change the document type declaration from XHTML 1.0 to HTML 4.01. (see DTD section for further explanation).</li>
<li>If present, remove the XML declaration. (Typically this is: &lt;?xml version="1.0" encoding="utf-8"?&gt;).</li>
</ol>
<img class="alignright" src="https://upload.wikimedia.org/wikipedia/commons/thumb/6/61/HTML5_logo_and_wordmark.svg/340px-HTML5_logo_and_wordmark.svg.png" />
<p>Those are the main changes necessary to translate a document from XHTML 1.0 to HTML 4.01. To translate from HTML to XHTML would also require the addition of any omitted opening or closing tags. Whether coding in HTML or XHTML it may just be best to always include the optional tags within an HTML document rather than remembering which tags can be omitted.</p>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment