Anatomy of an HTML file
HTML, or hypertext Markup Language, is a language that uses text and a defined set of commands (known as tags) to create a World Wide Web page.
- HTML
Every HTML page file has a beginning and an end. These are defined by 'beginning' and 'ending' tags. The tag <HTML> needs to be at the start of the code. - HEAD
The <HEAD> tag doesn't display on the web page, but you should get into the habit of putting it in. This tag is a container for all the head elements. These can include page title, scripts, style sheet instructions and most importantly provide meta information for search engine. - TITLE
The title tag defines the title of the document and is a required element in the head section. Each page should have a descriptive title that clearly identifies the content of the page and the site itself. It's best to use the name of your webpage, for instance: "Beginners Guide to HTML". - BODY
The body tag opens the document's body section. This section contains the main elements of an HTML document, such as hyperlinks text, pictures, tables, forms and lists. A well-written introduction will help to hook the user. When they enter they want a quick idea of whether the page is of interest - it's the text and graphical state of your site that will decide whether they stay or go. - /HTML
</HTML> at the end of the code. Note: The / in the second tag. All HTML end tags need to contain this character. This slash indicates an operation has finished. - P
The <P> tag is a paragraph tag. A <P> tag instructs a browser to create space above and below the tag, thus separating text into paragraphs. - H1
The <H1> to <H6> tags are used to define HTML headings and sub headings. <H1> displays the largest heading and <H6> displays the smallest heading.
<HTML>
<HEAD>
<TITLE>Beginners Guide to HTML</TITLE>
<H1>What is the structure of an HTML Page</H1>
<P>This is the source code (HTML file) used to make your own Web page.</P>
<P> This HTML code, can be saved as an HTML file. To do this write you code using a word processor then go to the file menu, choose SAVE AS and give your document a file name, for instance my homepage. Finally add the extention.html. as myhomepage.html</P>
</BODY>
</HTML>
0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home