Open In App
Related Articles

HTML | data value attribute

Improve Article
Improve
Save Article
Save
Like Article
Like

The HTML data value attribute is used to Specify the machine-readable translation of the content of the element.
Syntax: 

<data attribute> Contents... </data> 

Example:

html




<!DOCTYPE html>
<html>
 
<head>
    <title>data tag</title>
</head>
 
<body>
    <h1 style="color:green;">GeeksforGeeks</h1>
    <h2> HTML data value attribute </h2>
     
<p><b><i>GeeksforGeeks Subject List:</i></b></p>
 
    <ul>
        <li>
            <data value="009">
              Data Structure
          </data>
        </li>
        <li>
            <data value="010">
              Algorithm
          </data>
        </li>
        <li>
            <data value="011">
              HTML
          </data>
        </li>
        <li>
            <data value="019">
              Operating System
          </data>
        </li>
        <li>
            <data value="110">
              Computer Network
          </data>
        </li>
        <li>
            <data value="111">
              DBMS
          </data>
        </li>
    </ul>
</body>
 
</html>


Output:

Supported Browsers: The browsers supported by data value attribute are listed below:

  • Google Chrome
  • Internet Explorer
  • Firefox
  • Opera

 


Whether you're preparing for your first job interview or aiming to upskill in this ever-evolving tech landscape, GeeksforGeeks Courses are your key to success. We provide top-quality content at affordable prices, all geared towards accelerating your growth in a time-bound manner. Join the millions we've already empowered, and we're here to do the same for you. Don't miss out - check it out now!

Last Updated : 15 Jul, 2021
Like Article
Save Article
Previous
Next
Similar Reads
Complete Tutorials