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 | Flow content, phrasing content, palpable content. |
---|---|
Contenido permitido | Phrasing content. |
Omisión de etiqueta | None, both the starting and ending tag are mandatory. |
Elementos permitidos | Any element that accepts phrasing content. |
interfaz DOM | HTMLDataElement |
Atributos
Este elemento incluye Atributos globales
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.
<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 | Status | Comment |
---|---|---|
HTML Living Standard La definición de '<data>' en esta especificación. |
Living Standard | No change from HTML5 |
HTML5 La definición de '<data>' en esta especificación. |
Recommendation | Initial definition. |
Compatibilidad de navegador
We're converting our compatibility data into a machine-readable JSON format.
This compatibility table still uses the old format,
because we haven't yet converted the data it contains.
Find out how you can help!
Feature | Chrome | Firefox (Gecko) | Internet Explorer | Opera | Safari |
---|---|---|---|---|---|
Basic support | Sin soporte | 22.0 (22.0) error 839371 | Sin soporte | Sin soporte | Sin soporte |
Feature | Android | Firefox Mobile (Gecko) | IE Mobile | Opera Mobile | Safari Mobile |
---|---|---|---|---|---|
Basic support | Sin soporte | Sin soporte | Sin soporte | Sin soporte | Sin soporte |
Ver también
- The HTML
<time>
element.