Page 85 - modular_v2.0_HTML&_CSS_Fb
P. 85
ID: The id attribute is used to uniquely identify an element within a web page. When applied
to an anchor tag, it allows the anchor to act as an anchor point or bookmark that you can
link to within the same page or from a different page.
TARGET: This attribute is used to specify the place in which the linked web page will open.
It takes any one of the following four values:
• _blank: Opens the linked web page in a new window or tab of the web browser.
• _parent: Opens the linked web page in a parent window or tab of the web browser.
• _self: Opens the linked web page in current window or tab.
• _top: Opens the linked web page in the window that is on top in all the windows.
TITLE: This attribute is used to define the title of a link, which appears to the user as a
tooltip.
External web pages can be linked using HREF attribute of the anchor tag. The HREF attribute
takes the URL of the web page in double quotes.
First page of a website, also known as Home page contains various links of other web pages. Let
us take an example of a website of the ABC Public School in which we are using external linking.
The Home page of the website is as shown:
Output
Preceding web page contains six hyperlinks Admissions, Events, Sports, Activities, About Us and
Contact Us which are created by using the <A> tag.
The code to create the Home.html web page is as follows:
<!DOCTYPE HTML>
<HTML>
<HEAD>
<TITLE> Home Page </TITLE>
</HEAD>
<BODY STYLE="BACKGROUND-COLOR: #EEFFEE; COLOR: RED;">
<H1> ABC Public School </H1>
83
Images, Links and Frames in HTML

