Wednesday, May 12, 2010

When Was It Updated?

Have you ever been on a web site and wondered when it was last updated?
This information can come in handy for stuff like news sites, stock sites, and/or any site that has time critical information posted on it.

Anyhow, if you want to find out when a particular page was last updated, head to the page and type (or copy and paste) the following line into your address bar:

javascript:alert(document.lastModified)

Try it on this page! You'll get a message box that looks something like this (only with a different date/time):

(Note - your browser must be java-enabled in order to do this little trick. That should be 99.99% of you.)

OK, that's all well and good, but unless you're a web page designer, chances are you're not going to remember how to do that a month from now.

So, what can you do? Add it to your favorites.

Now, this is not nearly as easy as it sounds. If you just try adding it to your favorites, you'll find that it doesn't work, you get the web page you're visiting instead. So, here's a workaround (this is for Internet Explorer, BTW):

1. Add a web page to your favorites. It doesn't matter what page it is. When the "Add to favorites" screen pops up, re-name the page "Last Update" (no quotes) or something similar.

2. Now, click your Favorites menu and find the favorite you just added.
Right-click it and select Properties from the resulting menu. Not surprisingly, a properties screen pops up.

3. Finally, put the line below in place of the current URL:

javascript:alert(document.lastModified)

You'll probably get an error message when you change it. Just hit "Yes" if this pops up.

That should do it. Click the "Last Update" favorite anytime you're on a page and want to know when it was last updated.

0 comments:

Post a Comment

 
Design by Free WordPress Themes | Bloggerized by Lasantha - Premium Blogger Themes | fantastic sams coupons