HTML (Hypertext Markup Language) is the standard markup language used for creating web pages. Here are 12 basic elements of HTML:
- <!DOCTYPE html>: This is the first line of an HTML document, and it declares that the document is an HTML5 document.
- <html>: This is the root element of an HTML document, and it contains all other elements.
- <head>: This element contains meta information about the document, such as the title, scripts, and stylesheets.
- <title>: This element is used to specify the title of the document, which appears in the browser's title bar.
- <body>: This element contains the visible content of the document, such as text, images, and links.
- <h1> to <h6>: These elements are used to create headings, with <h1> being the largest and <h6> being the smallest.
- <p>: This element is used to create paragraphs of text.
- <a>: This element is used to create hyperlinks to other web pages or to specific locations within the same document.
- <img>: This element is used to insert images into the document.
- <ul> and <li>: These elements are used to create unordered lists, with <ul> representing the list itself and <li> representing each list item.
- <ol> and <li>: These elements are used to create ordered lists, with <ol> representing the list itself and <li> representing each list item.
- <div> and <span>: These elements are used to group other elements together and apply styles to them. <div> is used for larger groups, while <span> is used for smaller groups.
Tags:
basic of HTML