bLuEbLinX

Basic HTML

July 12, 2008

What is an HTML File?
HTML - [Hyper Text Markup Language] is a text file containing small markup tags.

<html> this is the start of an HTML document.
</html> this is the end of the HTML document.
<head></head> header information is placed between the tags. Header information is not displayed in the browser window.
<title></title> title of your document. The title is displayed in your browser’s caption.
<body></body> the text that will be displayed in your browser.

HTML Extension
When saving an HTML file, it is a good practice to use .html extension.

Basic HTML Tags
<html></html> an HTML document
<body></body> the document’s body
<h1> to <h6> header 1 to header 6
<p></p> a paragraph
<br> inserts a single line break
<hr> a horizontal rule
<!–> a comment

Text Formatting Tags
<b></b> bold text
<big></big> big text
<em></em> emphasized text
<i></i> italic text
<small></small> small text
<strong></strong> strong text
<sub></sub> subscripted text
<sup></sup> superscripted text
<ins></ins> inserted text

Computer Output Tags
<code></code> computer code text
<kbd></kbd> keyboard text
<samp></samp> sample computer code
<tt></tt> teletype text
<var></var> a variable
<pre></pre> preformatted text

HTML uses a hyperlink to link to another document on the Web.
The <a> tag is used to create an anchor to link from, the href attribute is used to address the document to link to, and the words between the open and close of the anchor tag will be displayed as a hyperlink.

<a href=”http://www.codedspirit.com/”>Welcome to kilometer69!</a>

The Target Attribute
With the target attribute, you can define where the linked document will be opened.
The line below will open the document in a new browser window:

<a href=”http://www.kilometer69.tk/”target=”_blank”>Welcome to kilometer69!</a>

Link Tags
<a></a> an anchor

Table Tags
<table></table> a table
<th></th> table header
<tr></tr> table row
<td></td> table cell
<caption></caption> table caption
<colgroup></colgroup> groups of table columns
<col></col> the attribute values for one or more columns in a table
<thead> table head
<tbody> table body
<tfoot> table footer

List Tags
<ol></ol> an ordered list
<ul></ul> an unordered list
<li></li> list item
<dl></dl> definition list
<dt></dt> definition term
<dd></dd> definition description

Form Tags
<form><form> form for user input
<input> an input field
<textarea> a text-area (a multi-line text input control)
<label> a label to a control
<fieldset> a fieldset
<legend> a caption for a fieldset
<select> a selectable list (a drop-down box)
<optgroup> an option group
<option> an option in the drop-down box
<button> push button

The Image Tag and the Src Attribute
In HTML, images are defined with the <img> tag.
The <img> tag is empty, which means that it contains attributes only and it has no closing tag.
To display an image on a page, you need to use the src attribute. Src stands for “source”. The value of the src attribute is the URL of the image you want to display on your page.

<img src=”url”>

The Alt Attribute
The alt attribute is used to define an “alternate text” for an image. The value of the alt attribute is an author-defined text:

<img src=”boat.gif” alt=”Big Boat”>

The “alt” attribute tells the reader what he or she is missing on a page if the browser can’t load images. The browser will then display the alternate text instead of the image. It is a good practice to include the “alt” attribute for each image on a page, to improve the display and usefulness of your document for people who have text-only browsers.

Image Tags

<img> an image
<map> an image map
<area> a clickable area inside an image map

Backgrounds
The <body> tag has two attributes where you can specify backgrounds. The background can be a color or an image.

Bgcolor
The bgcolor attribute specifies a background-color for an HTML page. The value of this attribute can be a hexadecimal number, an RGB value, or a color name:

<body bgcolor=”#000000″>
<body bgcolor=”rgb(0,0,0)”>
<body bgcolor=”black”>

Background
The background attribute specifies a background-image for an HTML page. The value of this attribute is the URL of the image you want to use. If the image is smaller than the browser window, the image will repeat itself until it fills the entire browser window.

<body background=”banner.jpg”>
<body background=”http://www.kilometer69/banner.jpg”>

Posted by blueblinx at 12:13 am | permalink

Previous Comments

Wow! This blog is relevant to Basic Html that one has to take full advantage of learning this process because it helps to increase the productivity of the business.

Posted by Basic Html at October 6, 2008, 8:14 pm

thanks!:)

Posted by blueblinx at October 9, 2008, 1:47 am

Add a comment








.: bLuRt iT oUt! :.

Jenny:

LOL

Jenny:

oh haha.

Miguel Guedes de Sousa:

Wow, thanks for the tip. This is one of the most useful I’ve found online.

sia:

but what should i put in between? hope you can help…thanks :)

sia:

Can I ask something?
Coz am working on my overlay, but Im stuck in putting codes to spawn the contents of friendster boxes like about me, comments, my friends, my media etc.. I start with like

sia:

salamat pareh>>> :)

sia:

salamat pareh>>> :)

Patrick:

thanks po ah.. sana mapagana ko…

blueblinx:

Hi guyz!^^,
Welcum 2 mY pAgE..

Enjoy!:)

Leave a message ▼