HTML Introduction to HTML and CSS Getting Familiar with HTML and CSS Welcome to HTML and CSS

"Attributes help us give the browser more information about how the tag should work or look." What does this mean?

I don't understand what is meant here, at all.

1 Answer

Aayush Mitra
Aayush Mitra
24,360 Points

I think an example would help you understand. For example if you have a link: <a>My Website!</a> That would give you a link but it would not know where to take you. So you give it an href attribute. <a href=“Http://www.mywebsite.com”>My Website!</a> The href ATTRIBUTE tells the browser where to send the user when they click on a link.

I hope this helps!

Thanks :)

Thanks so much, I really appreciate examples. It makes things much easier to grasp/understand. So you can modify the default behavior of the element, right?

So for example, in your example you are saying with the default behavior of the "a tag" it won't go anywhere, but you can modify this with an attribute, so that it does. Please correct me if I am wrong!

Aayush Mitra
Aayush Mitra
24,360 Points

Yes you are correct. :)