Computer Applications

Hyperlinks are the highlighted text segments or images that connect to other pages on the web. Based on this, answer the following questions:

a. Which tag is used to create a hyperlink and the attribute used to specify the path of the document to be linked?

b. Give an example of how an image "hello.jpg" can be used as a hyperlink.

c. What are internal links and external links in HTML?

HTML Advanced Features

2 Likes

Answer

a. The anchor tag <A> is used to create a hyperlink. The Href attribute is used to specify the path of the document to be linked.

b. Example of using image as a hyperlink:

<A href="https://www.example.com">
  <IMG src="hello.jpg" alt="Hello Image">
</A>

In this example, when a user clicks on the "hello.jpg" image, it will act as a hyperlink and take them to the "https://www.example.com" web page.

c.

  1. Internal Links — When one part of a web page is linked to another section of the same page, it is called an internal link. For example,
    <A HREF = "#section2"> Jump to Section 2 </A>
    Here, the "#" symbol followed by "section2" refers to an internal link within the same page to a section with the name "section2."

  2. External Links — When one page is linked to another web page or website, it is called external linking. For example,
    <A HREF = "https://www.example.com"> Visit Example Website </A>
    Here, the hyperlink points to an external website, "https://www.example.com," which is outside the current website's domain.

Answered By

1 Like


Related Questions