Let's practice creating an HTML document
and viewing it in the browser window.
Before you begin though, we'll need to
create a folder to store our work. For these activities we'll
store our work on
the Desktop. Create a new folder for
storing your work and name the new folder your last name for easy
identification.
The common HTML authoring environment is
to have your text or HTML editor running simultaneously with at
least one browser. As you create your HTML code in the editor, you
should frequently save, jump to the browser, and refresh your page
to check your work.
-
Launch a text editor such as Notepad.
Notepad will save the text in pure ASCII format without the
proprietary formatting that usually goes along with documents saved
in word processing programs like MSWord.
-
Type the following code to
create the basic structure of any web page:
<html>
<head>
</head>
<body>
</body>
</html>
-
Save your Web page to your
folder on the desktop. Give the document the .htm or .html extension before saving. This is very
important. Name the file yourlastname_kitchen.html
-
Continue to keep Notepad open and navigate to your newly created html
file. Double click on it and it should open in your browser window.
You will have two windows open and can now work back and forth between Notepad
and your browser.
-
After making changes in Notepad, choose save, and then
refresh in the browser window to see the changes. (If you close the
windows, just open your .html file again and choose view>source from the
menu to access the text file.)