<data>

Resúmen

El Elemento HTML <data> vincula un contenido dado con una traducción legible por una máquina. Si el contenido está relacionado con time- o date-, debe usarse el elemento <time>.

Categorías de contenido (en-US) Flow content (en-US), phrasing content (en-US), palpable content.
Contenido permitido Phrasing content (en-US).
Omisión de etiqueta None, both the starting and ending tag are mandatory.
Elementos permitidos Any element that accepts phrasing content (en-US).
interfaz DOM HTMLDataElement (en-US)

Atributos

Este elemento incluye Atributos globales (en-US)

value

This attribute specifies the machine-readable translation of the content of the element.

Ejemplo

El siguiente ejemplo muestra nombres de productos pero también asocia a cada uno con su código UPC.

html
<p>New Products</p>
<ul>
  <li><data value="3967381398">Mini Ketchup</data></li>
  <li><data value="3967381399">Jumbo Ketchup</data></li>
  <li><data value="3967381400">Mega Jumbo Ketchup</data></li>
</ul>

Especificaciones

Specification
HTML Standard
# the-data-element

Compatibilidad con navegadores

BCD tables only load in the browser

Ver también