Scene 1
Links
There are two types of links – Absolute and Relative.
Absolute link: It links to a page that is usually located outside your server.
Example: Link to ABC’s web site
Note: all the code goes inside and
Relative Link: Refers to a page that is inside your root folder or on your server.
Let us say if have a XHTML document named text.htm inside our pages folder and we
want to link to that page from our home page.
In the home page, let’s create a link –
Link to text page
Note: for the path, we have “pages/text.htm”. This means that pages is the name of the
folder and text.htm is the XHTML document that is inside that folder.
In the Tag, a stands for Anchor and href stands for hypertext reference.
Scene 2
Now, let us say we have two pages inside our pages folder – text.htm and images.htm and
let’s say we want to link from the text page to the images page.
In the Text page, let’s create a link –
Link to Images page
Note: for the path, we have “images.htm”. Here both the pages are inside the same folder.
So we do not need to specify the name of the folder.
Scene 3
Using Images as Links
Let’s say instead of Text you would like to use images as links. Let us say you have two
HTML documents inside your pages folder – tables.htm and text.htm and you have one
small image inside your images folder – button.jpg.
If you would like the button image to appear on your Text page then –
Note: “../images/button.jpg” denotes the path to the image.
1
To link the image:
Scene 4
Link to an email address
Contact Us
Note: Replace rupamisra@yahoo.com with your email address
2