"Date Last Edited" Automatically Updated on Save?
please let me know if possible automatically have "date last saved" updated on of web pages, , if so, steps going.
sure, it's not built dw though.
here's javascript trick. copy part new .js file , call "date.js"...
months = ['january', 'february', 'march', 'april', 'may', 'june', 'july', 'august', 'september', 'october', 'november', 'december'];
var d = new date();
var weekday = new array(7);
weekday[0] = "sunday";
weekday[1] = "monday";
weekday[2] = "tuesday";
weekday[3] = "wednesday";
weekday[4] = "thursday";
weekday[5] = "friday";
weekday[6] = "saturday";
var d = new date();
(d.getfullyear());
var thedate = new date(document.lastmodified);
thedate.settime((thedate.gettime()+(60*60)) )
with (thedate) {
document.write("<i>last updated "+weekday[getday()]+' '+months[getmonth()]+' '+getdate()+', '+d.getfullyear()+' @ '+gethours()+':'+getminutes()+" dst</i>")
}
here's base html page attaches date.js file. place bold part wherever want date show in page , make sure "path-to" part actual path .js file...
<!doctype html>
<html lang="en-us">
<head>
<meta charset="utf-8">
<title>add date last modified of document</title>
</head>
<body>
<script src="path-to/date.js" script type="text/javascript"></script>
</body>
</html>
More discussions in Dreamweaver support forum
adobe
Comments
Post a Comment