Sunday, 24 July 2016

New elements and attributes of HTML 5

New Elements
  1. Article: shows an independent entry of a blog or a magazine.
  2. Aside: shows a note, a tip, a sidebar, a parenthetical mark, or the content other than the main content
  3. Audio: allows you to embed audio files in a web page.
  4. BDI: allows you specify non left to right direction for a span of text.
  5. Canvas: provides a canvas on a web page to draw graphics on it.
  6. Command: stores a command to perform a task.
  7. Datalist: shows a drop down list.
  8. Details: shows the details of a item besides its default information.
  9. Embed: defines external interactive content or plug-in.
  10. FigCaption: shows the caption of the figure element.
  11. Figure: shows a group of media element., video and audio, along with a caption.
  12. Footer: shows the footer of the section or page.
  13. Header: shows the header of the section or page.
  14. HGroup: Represents a group of headings in a document.
  15. Keygen: Specifies an element that generates a pair of key( private and public) for forms, where the private key is stored locally with the submission of a form and the public key is sent to the server.
  16. Mark: shows highlighted text.
  17. Menu: shows a menu bar on the web page.
  18. Meter: displays the measurement of a number in a predefined range.
  19. Nav: shows a collection of links related to other web pages.
  20. Output: specifies an element that is used to display output.
  21. Progress: shows the progress of an ongoing process.
  22. RP: dictates the browser to show the content when they do not support the ruby element.
  23. RT: shows the details of ruby annotation.
  24. Section: shows a section or a part of a page.
  25. Source: represents a media resource.
  26. Summary: shows the summary of a details element.
  27. Time: shows a date and time in a web page.
  28. Video: allows you to embed videos in a web page.
  29. WBR: defines a possible line break that can be inserted in a text.

New Attributes
  1. accesskey: represents a keyboard shortcut to access an element.
  2. contenteditable: specifies whether or not a user is allowed to edit the content.
  3. contextmenu: represents the context menu for element.
  4. data-yourvalue: represents user defined attributes that must  start with the data-text.
  5. draggable: specifies whether or not a user is able to drag an element.
  6. dropzone: specifies the drop target for a dragged element.
  7. hidden: hides a non relevent element.
  8. spellcheck: specifies whether or not the spelling or grammar checking feature is enabled for an element.
Form Element New Attributes

  1. Autocomplete: specifies that the form text field can provide a list of options to automatically fill the field. 
          <form action="new.asp" method="get" autocomplete="on">
          </form>
     2. novalidate: specifies that form will not be validated when submitted.
         <form action="new_form.asp" novalidate="novalidate">
         </ form>

Input Element New Attributes
  1. autocomplete: specifies that an input field automatically fills the content.
  2. autofocus: input field automatically gets focus.
  3. form: specifies input field belongs to one or more form.
  4. formaction: specifies an attribute the overrides form action attribute.
  5. formenctype: specifies an attribute that overrides the form enctype attribute.
  6. formmethod: specifies an attribute that overrides the form method attribute.
  7. formnovalidate: specifies an attribute that overrides the form novalidate attribute.
  8. formtarget: specifies an attribute that overrides the form target attribute.
  9. height: specifies height of an image used as an input
  10. width: specifies width of an image used as an input.
  11. list: specifies data list for an input field.
  12. min: specifies minimum value that is allowed in the input field.
  13. max: specifies maximum value that is allowed in the input field.
  14. step: specifies an increment number for the input field that takes a range of numbers.
  15. multiple: specifies that multiple values can be selected for an input field.
  16. pattern: specifies a pattern used to validate an input field.
  17. placeholder: specifies a default text in the input field until focus the field for entering your text.
  18. required: specifies that an input field must be filled with data before submitting the form containing it.

Type Attributes New Values


  1. datetime: displays date and time on the basis of ISO 8601 with the time zone set to the UTC.
  2. datetime-local: displays date and time on the basis of ISO 8601 without the time zone information.
  3. date: displays the date on the basis of ISO 8601.
  4. month: displays date, consisting of year and month, on the basis of ISO 8601.
  5. week: displays date, consisting of a year and the number of the current week of the year, on the basis of ISO 8601.
  6. time: displays time on the basis of ISO 8601.
  7. number: allows a field to accept only numeric values and takes 1 as default number.
  8. range: allows a field to accept a value from a range of numbers.
  9. email: allows a field to accept only an email format value.
  10. url: allows a field that accept only the url format value.

0 comments:

Post a Comment