Pr.Pg Next Pg

<DATA>..</DATA> tag tutorials

  • The HTML data element is used for providing a machine-readable version of its own contents.

Note: This data element is in the WHATWG version of HTML and not in the W3C draft of HTML5. That means it is a highly experimental feature and shouldn't be use on Web sites.

  • Below table shows the attributes of <DATA> element tag:

 

Sr No

Attributes

Descriptions

1

class

This attribute specify one or more class names for an element refers to a class in a style sheet.

2

draggable

This attribute specifies whether an element is draggable or not.

3

hidden

This attribute specifies that an element is not yet, or is no longer, relevant.

4

id

This attribute specifies a unique id for an element in html page.

5

spellcheck

This attribute specifies whether the element is to have its spelling and grammar checked or not.

6

style

This attribute specifies an inline CSS style for an element.

7

title

This attribute specifies extra information about an element.

 

Syntax:

<body>

<data>some data..</data>

</body>

 

Example: HTML program to demonstrate data element

Output:
Pr.Pg border                                              Next Pg