Page 21 - Learn To Use HTML and CSS
P. 21

So You Want to Learn to Use HTML and CSS – Version 2020-06-12a                        Page 11
               Chapter 1 — A Brief History and Creating Your First Page


             Free
                <h1>The Best Ice-Cream
                <p>A paragraph about the best frozen goodness I have ever eaten.
                </h1>
                </p>


             eBook
               The example above is incorrect because the <h1>...</h1> ends after the <p>...</p>
               begins. You should not put any other tag inside a header tag.



                <h1>The Best Ice-Cream
                <p>A paragraph about the best frozen goodness I have ever eaten.</p>
                </h1>
             Edition

               This example is incorrect because the <p>...</p> is nested inside of the header. The
               <h1>...</h1> tag is not a container, but should be a description of the tags that follow it.

               Here is a correct example of nesting:
            Please support this work at

                <h1>The Best Ice-Cream</h1>
                <p>A paragraph about the best frozen goodness I have ever eaten.</p>
                                  http://syw2l.org
               Remember, proper nesting is one of the most important aspects of writing an HTML document.

                                                                               Free
               HTML Entities — Displaying Special Characters

               In an HTML document <, >, and & have a special meaning. You should not include them in the
               text of your pages as they will potentially confuse the web browser.  However, if you need to
                                                                                21
               add special symbols and Unicode characters to your page, you may do so using HTML Entities.
               The table below shows a few of the character entity mark-ups:
                                                                   eBook

                                             Entity            Character

                                             <              <

                                             ©            ©
                                                                Edition




               21     http://www.tutorialspoint.com/html5/html5_entities.htm

               Copyright 2020 — James M. Reneau PhD — http://www.syw2l.org — This work is
               licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.
   16   17   18   19   20   21   22   23   24   25   26