Wednesday, May 20, 2009

Creating an HTML Page

Creating an HTML Page {Please change brecket ( ) into this simble < >}

Introduction to HTML


What is an HTML File?

  • HTML stands for Hyper Text Markup Language
  • An HTML file is a text file containing small markup tags
  • The markup tags tell the Web browser how to display the page
  • An HTML file must have an htm or html file extension
  • An HTML file can be created using a simple text editor

A web page is created using a language called, Hypertext Markup Language,
better known as HTML Code. You can write your own coding within a plain text editor,
such as Note Pad, or use an HTML editor, which will write the code for you.

HTML codes, also referred to as HTML tags, are enclosed by the lesser than (<) and greater than (>) brackets
and may be written in capital or lower case letters.

The opening bracket is followed by an element, which is a browser command, and ends with the closing bracket.


An element may also be followed by attributes, which are words describing the properties of the element, and further instruct the browser.




Attributes are only contained in the opening HTML tags to the right of the element
and are separated by a space and followed by an equal (=) sign.

The value follows the equal sign and is enclosed in quotes.





Basic HTML Document Code Structure
Begin writing your HTML tags by creating your document's basic layout. Copy and paste this code into your text or HTML editor.




Your Page Title</span><span style="font-weight: bold;">





This area will contain everything that will be visible through a web browser, such as text and graphics.
All of the information will be HTML coded.

For a complete list of HTML codes, tags and examples, see the HTML chart below.



Save the file as "mypage.htm".

Start your Internet browser. Select "Open" (or "Open Page") in the File menu of your browser. A dialog box will appear. Select "Browse" (or "Choose File") and locate the HTML file you just created - "mypage.htm" - select it and click "Open". Now you should see an address in the dialog box, for example "C:\MyDocuments\mypage.htm". Click OK, and the browser will display the page.


Example Explained

The first tag in your HTML document is . This tag tells your browser that this is the start of an HTML document. The last tag in your document is . This tag tells your browser that this is the end of the HTML document.

The text between the tag and the tag is header information. Header information is not displayed in the browser window.

()The text between the

The text between the tags is the text that will be displayed in your browser.

The text between the and tags will be displayed in a bold font.


HTM or HTML Extension?

When you save an HTML file, you can use either the .htm or the .html extension. We have used .htm in our examples. It might be a bad habit inherited from the past when some of the commonly used software only allowed three letter extensions.

With newer software we think it will be perfectly safe to use .html.


Note on HTML Editors:

You can easily edit HTML files using a WYSIWYG (what you see is what you get) editor like FrontPage or Dreamweaver, instead of writing your markup tags in a plain text file.

However, if you want to be a skillful Web developer, we strongly recommend that you use a plain text editor to learn your primer HTML.


Frequently Asked Questions

Q: After I have edited an HTML file, I cannot view the result in my browser. Why?
A: Make sure that you have saved the file with a proper name and extension like "c:\mypage.htm". Also make sure that you use the same name when you open the file in your browser.

Q: I have edited an HTML file, but the changes don't show in the browser. Why?
A: A browser caches pages so it doesn't have to read the same page twice. When you have modified a page, the browser doesn't know that. Use the browser's refresh/reload button to force the browser to reload the page.

Q: What browser should I use?
A: You can do all the training with all of the well-known browsers, like Internet Explorer, Firefox, Netscape, or Opera. However, some of the examples in our advanced classes require the latest versions of the browsers.

Q: Does my computer have to run Windows? What about a Mac?
A: You can do all your training on a non-Windows computer like a Mac.

(All Things Is Copy This Site: www.w3schools.com For More Information Click This Link And Go this On The Site.)

No comments: