3 examples of attributes.
1 Like
@aarumane143
three examples of attributes in HTML
- The “src” attribute: This attribute is used to specify the URL of an image, audio, or video file that should be displayed on a webpage. For example, the following HTML code would display an image with the file name “myimage.jpg” located in the same directory as the HTML file:
“”
- The “href” attribute: This attribute is used to specify the URL of a link that should be displayed on a webpage. For example, the following HTML code would create a link to the Wikipedia homepage:
“Visit Wikipedia”
- The “class” attribute: This attribute is used to specify one or more classes for an HTML element. Classes are used by CSS to apply styles to specific elements on a webpage. For example, the following HTML code would create a paragraph element with the class “important”:
This is an important paragraph.
Thanks