What is hyperlink? What are different types of links available? Also explain the purpose of HREF attribute?
HYPERLINK
Hyperlink
is one of the most powerful feature of HTML. Usually a website consists of
number of pages and hyperlinks provide a way to establish link between these
webpage so that users can easily navigate from one page of the website to
another. A hyperlink is simply a unidirectional pointer from source to some
destination location.
TYPES
OF LINK
1.
INTERNAL LINK : It represents a link to
different webpage on the same website or different location on the same
webpage.
2.
EXTERNAL LINKS : It represents a link
to different webpage on different websites.
One can create three kinds of links in your website
·
Link to different webpage on the
current website
·
Link to different parts within the
current webpage.
·
Link to webpage on different websites.
HREF
The HREF
stands for hypertext reference that
contains the URL of the destination page to which link will move to. The URL’s
address specified can point to any type of file on the webpage such as HTML
document, images, sounds, movies etc. The general format for using <a>
tag is
<a href =
“URL”> Hyperlinked text </a>
Here, Hyperlinked
text act as hyperlink which when clicked by a visitor in a web browser will
activate the link and URL specified in href attribute will open, if link is
active.
Create a
webpage containing frequently asked questions about html whose answer are
present in the same page.
<Html>
<head>
<title>MCQ</title>
</Head>
<body>
<a name="bottom">
For Answers <a
href = "#bottom">Click here</a><br>
<hr>
<b>QUESTIONS :-</b>
<hr>
1. Who is Known as the "Father of Modern
Computer"?
<ol type="a">
<li>E.F. Codd<br>
<li>Charles Babbage<br>
<li>Dennis Ritchi<br>
<li>Stieve Job<br>
</ol>
<hr>
2. Which is the longest river in the world?
<ol type="a">
<li>Amazon<br>
<li>Bhramputra<br>
<li>Mississippi<br>
<li>Nile<br><br>
</ol>
<hr>
3. Who is the first President of India?
<ol type="a">
<li>Dr. Rajender Prasad<br>
<li>Dr. Sarvpalli Radha krishnan<br>
<li>R.K. Narayanan<br>
<li>Dr. Jakhir huassain<br><br>
</ol>
<hr>
4. Which planet is known as 'Earth twins'?
<ol type="a">
<li>Mars<br>
<li>Venus<br>
<li>Neptune<br>
<li>Mercury<br><br>
</ol>
<hr>
<a name="#bottom"><b>ANSWERS
:-</b>
<hr>
1. b<br>
2. d<br>
3. a<br>
4. b<br>
<a href="#top">Go to Top</a>
</body>
</html>
Comments
Post a Comment