Freedom The Open Source Way Contribute Articles or News to OSForgeOSForge HomeLogout from Forums
Contacting OSForgeOSForge HomeAbout OSForge
  

Root
Contribute News
Learning Corner
Linux Distributions
Linux Common FAQ's
Discussion Forums
Community Gallery
Links Directory
Search OSForge
Networking
Industry Updates
Linux & Open Source
Opinions
Press Release
Programming
Security
Web Development

White Paper
Likewise Software Receives Ready for IBM Tivoli Validation
Plat'Home Unveils Final Results of “Will Linux Work?” Contest
Zenoss Announces Record Quarterly Customer Growth amid Struggling Economy
Latest Open-Xchange Server Edition Simplifies Integration, Easily Customizable
Cluster Resources Works With IBM to Provide Moab Hybrid Cluster on iDataPlex
Cluster Resources to Deomonstrate Moab Hybrid Cluster on Windows HPC Server 2008
Cluster Resources to Provide Moab Hybrid Cluster Solution on New Cray CX1(TM)
Plat'Home Unveils Winners of “Will Linux Work?” Contest
Zenoss Core Recognized as Best Open Source Network Monitoring Solution

View More

Tutorial : Basics of HTML | Course 1
By : Antti Simonen Find more article by Antti Simonen on Web Development
Sunday the 2nd, February 2003 at 01:53 PM (EST)
Send this Story to a Friend Readers TalkBack (0) - 3018 Reads
Viewing Page 1 of 3

Printer Friendly Page Printable format
Send this Story to a Friend Foward to Email

In this article I'll show you the very basics of HTML language. We'll create our very first HTML page from the scratch while I'll explain things to you. This article is the first part from the serie of three articles covering the secrets of HTML language.

Introduction

To make a universal website which everyone could see, one needs a common language which every computer can understand. In World Wide Web this language is HTML (HyperText Markup Language). HTML is a very simple language. With HTML you can create online documents to World Wide Web. HTML language is standardized language and to create a valid HTML page you need to follow this standard. In this article everything is like it should be according to this HTML 4.01 standard. When you know more about HTML you notice that not everything can be done if we follow the standard so that?s when we have to break it. But that?s in another article. When you?ve read this article you already know how to make HTML page which you can upload into internet (we?ll discuss that in another article) where everyone can see it. Ok, let?s get started.

The HTML 4.01 standard is declared in http://www.w3.org/TR/html401/
You can browse that site while you read this article so you learn the same time how to take advantage of that specification.
You don?t need no special software to create HTML pages. Notepad will do just fine but there are also more sophisticated tools like Macromedia Dreamweaver, Adobe GoLive and many many more?some of them are free and some will cost you a fortune. But remember. There?s NOTHING you couldn?t do with pico what you can do with ie. Dreamweaver. So Notepad will do just fine now. Just make sure that the editor you are using saves the document as pure text type.

Structure of Page

HTML language consists of ?Tags?. Tags specify to web browser how to display the text in the page. These tags are in <open></close> format so the ?/? line closes a tag. Not all tags must be closed but you?ll learn them while you read this article.

HTML page includes few parts that are in every page you see in the WWW. Now let?s take a look at our first page, shall we?

First thing you must do is to declare the HTML version that you use, This is not a real must but is considered a good habit and it enables you to make valid HTML pages. HTML 4.01 specifies three DTD?s (Document type defination) and you must include one of them in your webpage. Each of these types vary in the elements they support. We?ll be using the ?loose? type which allows us to do something different than ?strict? (you can read more about DTD?s on http://www.w3.org/TR/html401/struct/global.html#didx-document_type_declaration-1). So our first line in our page is following:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">

This is the Document type Defination we just made. Now let?s continue our journey into HTML.

Next we?ll have to do following things: I?ll explain them in a moment

<HTML>
<HEAD>
<TITLE>My First HTML Page</TITLE>
<META HTTP-EQUIV="CONTENT-TYPE" CONTENT="TEXT/HTML; CHARSET=iso-8859-1">
</HEAD>
<BODY>

First comes the <HTML> tag. This tells that we?re dealing with HTML page and not something else. This tag will be closed in the very end of the page we?re making but first comes first so let?s continue.
Next tag is <HEAD> tag. Everything inside this tag is invisible to viewers. There are few things that can be inside this tag and one of those are the <TITLE> tag which tells the browser the title of our page. You can see a title of every webpage on the top left corner of the browser. You can write any title you want for the page but I used ?My First HTML Page? and after you?ve written it you close the tag with </TITLE> tag.
Now I?ll tell you few other things that can be inside the <HEAD> tag.Those things can be <META> tags which we?ll get in another article. Now we?ve put there one META tag that tells the browser that what kind of file it is handling and what character set it?s using. This is a must thing to do if we want to write valid HTML pages. We?re going to look better these META tags in another article. Other things to put inside the HEAD tags are <SCRIPT> tags which we?ll also cover in another article. Script tag usually includes Javascript code like you might have seen somewhere. But let?s close our head tag with </HEAD> tag and continue our way.
Then we?ll actually open the main tag in our page which is <BODY> tag. Everything inside of this tag will be displayed in website. So this is where you actually put the content of the page. We want something to be on the website so we write next ie.


  Next Page (2 of 3)
Reader Rating from 1-5

 

Poor very 

1

2

3

4

5
 very Excellent

Talkback

Post Your Talkback | View All Talkback (0 Posted)


 Currently there are no Talkback posted on "Tutorial : Basics of HTML | Course 1", Click here to be the first to post a talkback.


 
Scroll Up

   About | Term of Use | Privacy | Contact us | Tell a Friend | Advertise  

OSForge News RSS Feed