If you want to make the "last updated" info on your website automatically generated, you may use these codes:
the script tag should look like <script type="text/javascript">
also it is preferable to use the dom to insert content into the page, not document.write.
in the head:later on in the body:PHP:<script type="text/javascript">onload = function(){
document.getElementById("lastModified").innerHTML = "Page last changed " + document.lastModified.split(" ")[0];
}</script>good read: http://www.quirksmode.org/js/lastmod.htmlHTML:<span id="lastModified"></span>
No comments:
Post a Comment