HTML TAGS
Eg: <b>My Cat name is Jai.</b>
Here in this example the main parts of element are:
Opening tag: This consists of the name of the element (in this case, b), wrapped in opening and closing angle brackets. This states where the element starts to take bold effect to text.
Closing tag: This includes a forward slash before the element name of open tag. This states where the element ends effect of bold text. Failing to include a closing tag is one of the common beginner mistake and can lead to strange results.
Content: This is the content of the element, which in this case is just given text.
Element: The opening tag, the closing tag, and the content together comprise the element.
HTML Headings:
HTML headings are defined with the <h1> to <h6> tags.
Eg: <h1> defines the most important heading. <h6> defines the least important heading:
<h1>This is heading 1</h1>
<h2>This is heading 2</h2>
.
.
.
<h6>This is heading 6</h6>
HTML Paragraphs:
HTML paragraphs are defined with the <p> tag:
Eg: <p>This is a paragraph.</p>
HTML Links:
HTML links are defined with the <a> tag:
Eg: <a href="https://www.w3schools.com">This is a link</a>
The link's destination is specified in the href attribute.
Attributes are used to provide additional information about HTML elements.
HTML Images:
HTML images are defined with the <img> tag.
The source file (src), alternative text (alt), width, and height are provided as attributes:
Eg: <img src="w3schools.jpg" alt="W3Schools.com" width="104" height="142">
HTML Buttons:
HTML buttons are defined with the <button> tag:
Eg: <button>Click me</button>
HTML Lists:
HTML lists are defined with the <ul> (unordered/bullet list) or the <ol> (ordered/numbered list) tag, followed by <li> tags (list items):
Eg: <ul>
<li>Morning</li>
<li>Afternoon</li>
<li>Night</li>
</ul>
No comments:
Post a Comment