Deaper visits a software vendor's website every once in a while to check if they've announced any new products, services, rates, or the like. One thing he noticed was bit silly about their site is that, although content is updated every few weeks, they had a big block of text stating that the last update just happened to be done on the same day you were visiting the site.

Of course that's really notable in the grand scheme of things. But on a more recent visit, Deaper noticed that their page did claim to be updated on the same day of the visit, just on the previous year. Curious as to how this might have happened, Dearper did a quick view source on the page and found these fun bits of JavaScript ...

<script language="JavaScript"><!--
  Time = new Date();
  CurrentTime = Time.getHours();
  if (CurrentTime < 12)
	{
    document.write("Last Update:");
  }
	  else
	{
    if (CurrentTime < 17)
		{ 
      document.write("Last Update:");
		}
		else
		{
		  document.write("Last Update:"); 
		}
	}
// --></script>

<script language="JavaScript"><!--
	var now = new Date();
	var monthName = now.getMonth() + 1;
	var dayName = now.getDay() + 1;
	var dayNumber = now.getDate();
	if(dayName==1) Day = "Sun.";
	if(dayName==2) Day = "Mon.";
	if(dayName==3) Day = "Tue.";
	if(dayName==4) Day = "Wed.";
	if(dayName==5) Day = "Thur.";
	if(dayName==6) Day = "Fri.";
	if(dayName==7) Day = "Sat.";
	if(monthName==1) Month="Jan.";
	if(monthName==2) Month="Feb.";
	if(monthName==3) Month="Mar.";
	if(monthName==4) Month="Apr.";
	if(monthName==5) Month="May";
	if(monthName==6) Month="June";
	if(monthName==7) Month="July";
	if(monthName==8) Month="Aug.";
	if(monthName==9) Month="Sept.";
	if(monthName==10) Month="Oct.";
	if(monthName==11) Month="Nov.";
	if(monthName==12) Month="Dec.";
	document.open();
	document.write(Month + " " + dayNumber + ", 2004");
// --></script>