HTML and CSS Reference
In-Depth Information
tags. The words “Hello World” are typed on a line between the body tags. See Figure 2.1
for a screenshot of the code as it would appear in Notepad. You have just created the
source code for a Web document.
Figure 2.1
Source code of
hello.html
FAQ
Do I have to start each tag on its own line?
No. A browser can display a page even if all the tags follow each other on one line with no
spaces. Humans, however, find it easier to write and read XHTML if line breaks and indentation
(more on this later) are used.
Save Your File
You will save your file with the name of hello.html. Web pages use either an .htm or
.html file extension. Select File from the menu bar, and then select Save As. The Save As
dialog box appears. Using Figure 2.2 as an example, type the file name.
Figure 2.2
The Save As dialog
box
FAQ
Why does my file have a .txt file extension?
In some older versions of Windows, Notepad will automatically append a .txt file extension. If
this happens, type the name of the file within quotes, “hello.html”, and save your file again.
 
Search WWH ::




Custom Search