JB
|
| Posted: 11/19/2002, 6:58 AM |
|
Does anyone know how I could insert This Page was last updated : 1/1/1111.. But have the date be the last time the database was updated? I can do it easily if I edit the page in Dreamweaver, but then it is not dynamic and will not update unless I modify the HTML again in Dreamweaver.. There has to be a way to do this with ASP ?
Thanks-
|
|
|
 |
Bill
|
| Posted: 11/19/2002, 10:30 AM |
|
<script language="javascript">
<!--
document.write('Last modified '+document.lastModified);
//-->
</script>
Last modified 11/19/2002 18:36:58
Bill
|
|
|
 |
JB
|
| Posted: 11/20/2002, 6:28 AM |
|
I used the javascript function:
<script language="javascript">
<!--
document.write('Last modified '+document.lastModified);
//-->
</script>
But this changes the date & time everytime I refresh the page. What I need
is for the page to say This Site last updated: xxxxx when the Database is updated.. Is there a way to do this?
Thanks-
|
|
|
 |
Andrew B
|
| Posted: 11/25/2002, 12:17 PM |
|
Um, well, since you are using the database, why don't you store the last mod date in the database?
How you do this would depend on the database you are using. Just add a date/time column to the table and update that with the current time when the record is updated.
When you show the record detail there are several ways to get it out and display it. Create a record form just like the one that you use to edit, with the same parameters. Remove all the buttons, etc. and only show the date field. Show it as a label, not a text box.
If you know code, you could just do a dlookup() to get the date out, and then show that on a menu form.
|
|
|
 |
|