Javascript examples for DOM:Document lastModified
The lastModified property returns the date and time the current document was last modified.
This property is read-only.
A String, representing the date and time the document was last modified
The following code shows how to get the date and time the current document was last modified:
<!DOCTYPE html> <html> <body> <button onclick="myFunction()">Test</button> <p id="demo"></p> <script> function myFunction() {//w ww. j ava 2 s. c o m var x = new Date(document.lastModified); document.getElementById("demo").innerHTML = x; } </script> </body> </html>