Code-1

HTML Tags

Standard Attributes

All HTML elements can have attributes. Attributes provide additional information about elements. Attributes are always specified in the start tag. Attributes usually come in name/value pairs like: name=”value”.

Tags

Tag Description
<!--...--> Defines a comment
<head> Contains metadata/information for the document
<header> Defines a header for a document or section
<footer> Defines a footer for a document or section
<body> Defines the document’s body

Tag | Description ——————–|——————– <!DOCTYPE> | Defines the document type <title> | Defines a title for the document <link> | Defines the relationship between a document and an external resource (most used to link to style sheets) <style> | Defines style information for a document <meta> | Defines metadata about an HTML document

Layout, Text and Images

Tag | Description —————————-|—————————- <a> | Defines a hyperlink <img> | Defines an image <blockquote> | Defines a section that is quoted from another source <code> | Defines a piece of computer code <ol> | Defines an ordered list <ul> | Defines an unordered list <li> | Defines a list item <h1> to <h6> | Defines HTML headings <div> | Defines a section in a document <span> | Defines a section in a document <p> | Defines a paragraph <br> | Defines a single line break <em> | Defines emphasized text <b> | Defines bold text <strong> | Defines important text <i> | Defines a part of text in an alternate voice or mood <sub> | Defines subscripted text <s> | Defines text that is no longer correct <center> | Defines centered text (Not supported in HTML5. Use CSS instead.)

Form and Input

Tag | Description ——————–|——————– <form> |Defines an HTML form for user input <input> |Defines an input control <textarea> |Defines a multiline input control (text area) <button> |Defines a clickable button <select> |Defines a drop-down list <optgroup> |Defines a group of related options in a drop-down list <option> |Defines an option in a drop-down list <label> |Defines a label for an <input> element <fieldset> |Groups related elements in a form <legend> |Defines a caption for a <fieldset> element <datalist> |Specifies a list of pre-defined options for input controls <output> |Defines the result of a calculation