HTML Elements
An HTML element is everything from the start tag to the end tag:Start tag /opening tag | Element content | End tag /closing tag |
---|---|---|
<p> | This is a paragraph | </p> |
<a href="default.htm" > | This is a link | </a> |
<br /> |
Nested HTML Elements
Most HTML elements can be nested (can contain other HTML elements).<body>
<p>This is my first paragraph.</p>
</body>
The <body> element defines the body of the HTML document.
The element has a start tag <body> and an end tag </body>.
The element content is another HTML element (a <p> and </p> element).
Don't Forget the End Tag
Some HTML elements might display correctly even if you forget the end tag:because the closing tag is considered optional.
Never rely on this. Many HTML elements will produce unexpected results and/or errors if you forget the end tag .
HTML Tip: Use Lowercase Tags
HTML tags are not case sensitive: <P> means the same as <p>. Many web sites use uppercase HTML tags.W3Schools use lowercase tags because the World Wide Web Consortium (W3C) recommends lowercase in HTML 4, and demands lowercase tags in XHTML.
<Back 1 2 3 4 5 6 7 8 9 10 11 Next>
0 comments:
¿Te animas a decir algo?