0

Question from a complete novice about HTML

How come when you use an anchor for Hyperlinks, it’s written as <a and not <a> like every other tag I’ve encountered so far?

9th Sep 2023, 10:16 AM
Stephen
3 RĂ©ponses
+ 3
Stephen Both are same <a href = " "> Opening and closing tag will be used for anchor with hyperlink.
9th Sep 2023, 11:26 AM
R🍁🇼🇳
R🍁🇼🇳 - avatar
+ 5
You will learn more about this in the course. But for now. href is an attribute of the <a> tag. It specifies the URL (web address) that the hyperlink points to. For example: <a href="https://www.sololearn.com">Sololearn</a> This creates a clickable link. However if you only do this. Example: <a>Sololearn</a> You will get a word but it will not be clickable.
9th Sep 2023, 8:56 PM
Chris Coder
Chris Coder - avatar
+ 2
Thank you, i didnt realise the whole href was inside the first tag, its not explained why in the super basics
9th Sep 2023, 12:44 PM
Stephen