Viewing and Analyzing HTML Source Code
Prerequisite:
Written Web pages
Purpose:
To be able to view, analyze, and edit the HTML source code for documents on the Web
Lesson:
You may have already started writing and editing your Web pages. One of the most common reasons to view source code is to look for the cause of a broken image or link. After the HTML source code is checked, PageMill can be used to make any necessary changes. Or, changes can be made in the source code as you are viewing it. Common tags were given on the HTML tutorial to assist you. Also, on the HTML tutorial page you can find links to Web pages containing more information about writing HTML documents.
There might be times when you need to look at the source code of other documents on the Web. Sometimes the code gives you an idea of how someone did something. You may also find out what was used to create the document both in text, graphics, animation, etc.
Two instructions for viewing raw HTML are used for comparison: one using PageMill and another using Netscape. They are meant to show you how to view the source code.
You can analyze Web pages either way to see if you can determine how they were written.
To view from Netscape, Internet Explorer, or Safari:
Go to View and scroll down to Page Source (or Source in other versions):
- The page will open using SimpleText (MAC) or Notepad or WordPad (PC). If the page does not open, check your browser General Preferences to check how you are viewing your document source. If there is no application set for view source, use Browse to select a word processor to view the document. It is recommended to keep this processor simple to conserve your memory.
- When you view a page, notice the tags with which you are familiar. Try to analyze the attributes you do not know. Printing a copy of the Web page and then a copy of the source code to analyze side by side is sometimes helpful.
- You can not make any changes to the page on remote server. To make changes you would need to save a copy onto your own computer. This protects the author of the Web page to a certain degree. Remember that if you use anything from a Web page in your pages, you should contact the author to let them know and to obtain permission.
- Try using tags you were not previously familiar with in a new Web page. What do the tags create?
- If you need to transfer a file back to the server after changes are made, use a file transfer transfer protocal such as Fetch or Ws_FTP.
Task:
Look at two Web pages: one that you have written and one on the Web. Using raw HTML insert a graphic, text, and links into a new Web page. Check with your facilitator or your course assignment page to see if you are expected to send the results of this task in as an assignment.