[HTML]Anchor Tag

Intro

As per merriam-webster.com dictionary hyperlink means a “highlighted word or picture in a document or Web page that you can click on with a computer mouse to go to another place in the same or a different document or Web page.”

Hyperlinking is very important in a website. By this, a user a can easily navigate from one webpage to another.

You may skip these paras

Imagine the world of the internet without a hyperlink. You are reading an article in a webpage and at that moment you see a great article stick on the sidebar and after that, you may click on it. But it would not be going to open (because it is the world without hyperlinks). So what’ll you do? Might you copy-paste the code in the Address bar?

Want I want to say is that without hyperlinks internet is the web.

The Code

So, coming to the point I am going to tell how to create a hyperlink.

Take a glance at the code below.

 

<a href="#">This is a link</a>

 

as you can see the hyperlink text is wrapped inside <a>...</a>.

 

the link will be placed between double quotes “…” where the Hash   is placed above.

 

PS

Use our try it editor and have fun with these codes. Do mistakes because mistakes will make you a better programmer.

Well, this is not the end. There is much more to be taught in HTML.

You may practice this for now or Take a rest. After that come to read our next article on to learn further.

 

Supported Browsers

Well, it is one the common and ordinary tag so it is supported by all of the popular browsers.

Chrome Firefox Opera Safari Edge
Yes Yes Yes Yes Yes

 

 

Attributes

  • href