// JavaScript Document
function displayDate(){
	var showDate = new Date();
	monthArray = new Array("January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December");
	dayArray = new Array("Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday");
	monthName = monthArray[showDate.getMonth()];
	dayName = dayArray[showDate.getDay()];
	dateValue = showDate.getDate();
	if(dateValue < 10) {
		dateString = "0" + dateValue;
	}
	else {
		dateString = dateValue;
	}
	
	hourValue = showDate.getHours();
	minuteValue = showDate.getMinutes();
	if(hourValue >= 12) {
		if(hourValue > 12) {
			hourValue = hourValue - 12;
		}
		amPm = " PM";
	}
	else {
		amPm = " AM";
	}
	if(hourValue < 10) {
		hourString = "0" + hourValue;
	}
	else {
		hourString = hourValue;
	}
	if(minuteValue < 10) {
		minuteString = "0" + minuteValue;
	}
	else {
		minuteString = minuteValue;
	}

	displayString = dateString + "  " + monthName + ",  " + showDate.getYear() + "  " + dayName + "  " + hourString + ":" + minuteString + "  " + amPm;
	document.write(displayString);

}
