Essential HTML Tags
1. Basic Structure Tags:
<!DOCTYPE html>: Declares the document type and version of HTML.<html>: Root element that contains all the content on the page.<head>: Contains meta-information like the title, character set, and links to external files.<title>: Sets the title of the page (displayed on the browser tab).<body>: Contains the visible content of the webpage.
2. Text Formatting Tags:
<h1>,<h2>,<h3>,<h4>,<h5>,<h6>: Headings (from largest<h1>to smallest<h6>).<p>: Paragraph.<br>: Line break.<b>: Bold text.<i>: Italic text.<u>: Underlined text.<strong>: Defines important text (bold by default).<em>: Defines emphasized text (italic by default).
3. Link and Image Tags:
<a>: Defines a hyperlink. (hrefattribute for the link destination).<img>: Embeds an image. (srcattribute for image location,altattribute for text description).
4. List Tags:
<ul>: Unordered list (bullets).<ol>: Ordered list (numbers).<li>: List item (used inside<ul>or<ol>).
5. Table Tags:
<table>: Defines a table.<tr>: Defines a table row.<td>: Defines a table cell (data).<th>: Defines a table header.
6. Form Tags:
<form>: Defines an HTML form.<input>: Defines an input field (can specify types like text, password, submit).<textarea>: Defines a multiline text input.<button>: Defines a clickable button.<label>: Defines a label for an input element.
7. Semantic Tags:
<header>: Defines a header for the page or section.<footer>: Defines a footer for the page or section.<article>: Defines content that is self-contained (e.g., a blog post).<section>: Defines a section of content.<nav>: Defines navigation links.<aside>: Defines content aside from the main content (e.g., sidebar).
8. Meta and Style Tags:
<meta>: Defines metadata about the HTML document (e.g., charset, viewport).<link>: Specifies external resources, like stylesheets.<style>: Embeds CSS styles directly in the document.
Comments
Post a Comment