Run ❯
Get your
own
website
Result Size:
625 x 565
×
Change Orientation
Save Code
Change Theme, Dark/Light
Go to Spaces
<!DOCTYPE html> <html> <body> <p>This is a text. <ins id="myIns" datetime="2012-09-15T22:55:03Z">This is an inserted text.</ins> </p> <p>Click the button to return the value of the datetime attribute of the inserted text.</p> <p id="demo"></p> <button onclick="myFunction()">Try it</button> <script> function myFunction() { var x = document.getElementById("myIns").dateTime; document.getElementById("demo").innerHTML=x; } </script> </body> </html>