Note on Create Hyperlink Table

  • Note
  • Things to remember

Create Hyperlink

A hyperlink allows linking to any other Web page. HTML allows linking to other HTML documents as well as images. Clicking on a section of text or image will open the Web site, an image, a bookmark or any linked Web page. The text or an image that provides such linkages is called HYPERTEXT, HYPERLINK or a HOTSPOT. It is normal for HTML documents to contain links to another document, which can be located anywhere on the Web. These links are provided by URLs (Uniform Resource Locator), which give the location and filename of a document.

The following elements represent links to another document. <A HREF=”URL”> </A>: The HREF attribute of the anchor element specifies a URL. If this attribute has a value, the contents of the <A> </A> element will be highlighted when the document is displayed in a browser window and clicking on this content will cause the browser to attempt to open the file specified by the URL.

Example:

<A HREF=http://www.w3school.com> W3school Website </A>. In this example, the text “W3school Website” represents the contents that would be highlighted as a link to the file named as the value of HREF.

Link Types

There are three major types of links;

  1. Internal link (Intra-page hyperlink link different parts of the same page).
  2. Local link (Inter-page hyperlink link different pages).
  3. External link (link different Web site).

  • Internal Links (Intra-page Hyperlink)

These are links within a document which help in the navigation of large documents. For example, we use “move to top” link on some of the Web page to navigate at the top of the document. To use internal link, NAME attribute and HREF attribute of <a> tag are used.

For Example:

<A NAME=”TOP”>Write what you like. </A>

</A> tag must be included, but no any text is required between <A> and </A>. Now, to link to that particular point in the Webpage, HREF attribute of <A> is used as following:

<A HREF=”#TOP”>GO TO TOP</A>

The # symbol identifies the word “top” as a named point within the current document, rather than a separate document.

  • Local links (Inter-page Hyperlink)

These are links to other Web pages of the same Web site. It can be used to point any resources like an HTML page, an image, a sound file, a movie file, etc. The format for creating local links is;

<A HREF=”URL”> text to be displayed </A>

Local links can be the full URL (complete e.g.http://www.syshouse.sales.report.htm) or partial (Relative to current directory e.g. /sales/report.htm).

  • External links

These are links to the Web page of another Web site. For example, if we are using hotmail.com and we got emails containing links to another Web site, then those links are called external links which are the full URL.

What is URL?

URL stands for Uniform Resource Locator. A URL is a standard way of referencing a protocol, a host name, a port, and a directory/path.

Protocal: //host name: port/directory path

Example:http://www.syshouse.com:80/default.htm

Example:

<HTML>
<HEAD> <TITLE> USING HYPERLINK </TITLE> </HEAD>
<BODY>
<H1>
LOCAL HYPERLINK </H1><BR>
<A NAME="TOP"> </A>
<A HREF="#TOp"> GO TO TOP </A>
<BR>
<H1>INTERNAL HYPERLINK </H1>
<BR>
<A HREF="COMPUTER.HTML"> COMPUTER </A>
<BR>
<H1>EXTERNAL HYPERLINK</H1>
<BR>
<A HREF="http://www.W3school.com"> W3school </A>
</H1>
</TABLE>
</BODY>
</HTML>

.

Create Table

A table is a two-dimensional matrix, consisting of rows and columns. Tables are intended for displaying data in rows and columns on the Web page. All table tags are included between the <TABLE></TABLE>. The <TABLE> </TABLE> element has four sub-element.

NAME OF ELEMENT

OPENING TAG - CLOSING TAG

Table Row

<TR> …………………</TR>

Table Heading

<TH>……………..</TH>

Table Data

<TD>…………………</TD>

Caption

<CAPTION>……………..</CAPTION>

The table row elements usually contain table header elements or table data elements. The table header and table data element can contain several body elements, which allows for rich formatting of the data in the table.

Tables are used a great deal in the creation of Web pages. They allow you to create boundaries that make positioning easier. They are great for formatting forms.

Table Attributes

  1. BGCOLOR:Some browsers supports background color in the table. The color selected will be expressed as an r (red), g (green), and b (blue) format for example.
  2. <TABLE BGCOLOR=”rgb (10,225,240)></TABLE>. Here, 10, 255, 240 represents the color intensity of red, green and blue respectively. One can directly type the color name. For example, <TABLE BGCOLOR=”green”></TABLE>.
  3. WIDTH:One can specify the table width as an absolute number of pixels or percentage of the document width. The width corresponds to the WIDTH attribute of the TABLE element.
  4. BORDER:The lines that form the boundary of each table cell when the table is displayed in a browser is border attribute. One can choose a numerical value for the border width, which specifies the border in pixels. A setting of BORDER=”0” will make the border disappear.
  5. CELLSPACING:Cell spacing represents the space between cells in pixels.
  6. CELLPADDING:Cell padding is the space between the cell border and cell contents in pixels.
  7. ALIGN:Tables can have left, right or center alignment.
  8. BACKGROUND:This attribute will set the background image of the table.
  9. BORDERCOLOR:The attribute will set the color outline to a border of the cell.

Table Caption

A table caption allows specifying a line of text that appears centered above or below the table. This acts like a title for the table.

<TABLE BORDER=”1” CELLSSPACING=”2”>

<CAPTION ALIGN=”BOTTOM”> Label for my table </CAPTION>

Merging table

Here`s the example of merging columns with row:

<HTML>

<HEAD> <TITLE> MERGING COLUMN </TITLE> </HEAD>

<BODY>

<TABLE BORDER="1">

<TR> <CENTER> <TD COLSPAN="3"> TELEPHONE NUMBERS </TD>

</TR>

<TD> 100 </TD> <TD> 101 </TD> <TD> 103 </TD>

<TR>

</TABLE>

</BODY>

</HTML>

.

Table header

Cells can be TH elements which result in the contents of the table header cells appearing centered and in bold text. Table data cells are also expressed by TD element.

Table Data and Table Header Attributes

COLSPAN:IT specifies how many cell columns of the table should be merging.

ROWSPAN:It specifies how many cell rows of the table should be merging.

ALIGN:It aligns cell data to left, right or centered alignment.

VALIGN:It aligns cell data to a top, middle or bottom alignment.

BACKGROUND:It sets background image will be tiled at the background of the tablet.

BGCOLOR:It sets the specific colors at the back of table area.

Example:

<HTML>
<HEAD> <TITLE> CREATING TABLE </TITLE> </HEAD>
<BODY>
<TABLE BORDER="1">
<TR>
<TH> COLUMN 1 HEADER </TH>
<TH> COLUMN 2 HEADER </TH>
<TR>
<TD> ROW 1 - COL 1 </TD> <TD> ROW 1 - COL 2 </TD>
</TR>
<TR>
<TD> ROW 2 - COL 1 </TD> <TD> ROW 2 - COL 2 </TD>
</TR>
</TABLE>
</BODY>
</HTML>SCROLLING TEXT tag

.

<MQRQUE> tag displays the content as a moving tag. It is a paired tag. So, the contents should be enclosed in between the <MARQUE> and </MARQUE>

Format: <MARQUE> BEHAVIOR=”Alternate” or “Slide” DIRECTION=”Left” or “Up” or “Down” BGCOLOR=”color name” or “#RRGGBB”> Text to be moved </MARQUE>

(Shrestha, Manandhar and Roshan)

Bibliography

Shrestha, Prachanda Ram, et al. Computer Essentials. Kathmandu: Asmita's Publication, 2014.

Create Hyperlink

A hyperlink allows linking to any other Web page. HTML allows linking to other HTML documents as well as images. Clicking on a section of text or image will open the Web site, an image, a bookmark or any linked Web page. The text or an image that provides such linkages is called HYPERTEXT, HYPERLINK, or a HOTSPOT.

There are three types of Hyperlink:

  1. Internal Hyperlink
  2. Local Hyperlink
  3. External Hyperlink

Create table

A table is a two-dimensional matrix, consisting of rows and columns. Tables are intended for displaying data in rows and columns on the Web page. All table tags are included between the. The element has four sub-element. Under the table, it has many table attributes.

 

.

Very Short Questions

0%

DISCUSSIONS ABOUT THIS NOTE

You must login to reply

Forum Time Replies Report
Web page

How to create a link with 5 web pages


You must login to reply