At this point, you might be tempted to say that you cannot learn these tags and can get along without using them by using one of the special HTML editors. The editors can help you, but these too require learning. They often throw in extra tags and inappropriate references for images and other files, making it difficult to move your project to a new computer. The biggest reason to learn the tags is that you will need to know HTML to write the PHP and ASP scripts to produce HTML. It really is not that difficult. Tags begin and end; you need to remember the opening and closing pointy brackets. You need to write attribute values, such as image filenames, and use quotation marks around them. You need to pay attention to opening and closing of tag pairs. If you fail to include a </a> tag, for example, the rest of the document will be a link.
A problem in writing HTML that you might be wondering about if you have done any programming of languages such as C++ and Java is that no program catches what to you are obvious errors. Neither the text editor nor the browser catches an error, such as not including a closing tag or mistyping the tag for a level-one header as the letter h followed by the lowercase l. Instead, the browser always displays something. You need to look at the display and confirm that it is what you intended. If there are problems, you need to examine the source file to see what the error is. The browser is forgiving of errors. It also ignores things like improperly nesting tags:
<b><i>Italic and bold </b> </i>
You can also mix upper- and lower-case for the tags: <BODY> or <body> or <boDy>.
As we have indicated, the HTML system does not specify exact display. This can be unfortunate in cases when you really need to specify formatting. Technologies, products, and standards exist now to address some of the formatting issues. These include cascading style sheets (CSS), eXtensible Markup Language (XML), and eXtensible Stylesheet Transform (XSL). We mention these acronyms to give you terms for reference and will not address them in this book.
The HTML language is constantly evolving. One emerging standard is called XHTML, or extensible HTML. It requires us to be more careful about properly nesting the tags, using lowercase for HTML tags, and using quotation marks around all attribute values. We tried to do that in this text, but you might see examples elsewhere that do not follow these rules. Another rule of XHTML is that the so-called singleton tags, such as for line break and images, must contain a closing slash:
<br /> <img src="/books/2/886/1/html/2/heart.gif" />
We do not follow that rule here because some of the older browsers actually complain. However, you might see this usage elsewhere.
There are more attributes for these tags and there are more tags. However, what you have learned so far provides substantial functionality. You can learn more tags by examining the HTML source code for existing pages. You see the source by using the View command on the browser toolbar and clicking on View Page Source, or by clicking the right mouse button and clicking on View Page Source. You can also use the Web to find online tutorials or references.