/**
 * Display the current date in the specified "holder."
 *
 * @param				holderId				A String containing the ID of the element in which to write the date.
 * @param				date						A Date object containing the date to write out.
 */
function writeDate(holderId, date) {
	var holder, monthDay, dateString, weekdays, suffix;
	
	if (!document.getElementById) return false;
	if (!document.createTextNode) return false;
	if (!document.getElementById(holderId)) return false;
	
	// Initialise some variables
	weekdays = ["Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"];
	months = ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"];
	holder = document.getElementById(holderId);
	
	// Create the date string
	dateString = weekdays[date.getUTCDay()] + ", " + date.getUTCDate();
	
	// Sort out the day suffix
	suffix = "th"
	if ((date.getUTCDate() < 10) || (date.getUTCDate() > 20)) {
		monthDay = date.getUTCDate.toString();
		if (monthDay.substr(monthDay.length - 1) == "1") suffix = "st";
		if (monthDay.substr(monthDay.length - 1) == "2") suffix = "nd";
		if (monthDay.substr(monthDay.length - 1) == "3") suffix = "rd";
	} // if
	
	dateString += suffix + " " + months[date.getUTCMonth()] + ", " + date.getUTCFullYear();
	
	// Append the date string to the holder
	holder.appendChild(document.createTextNode(dateString));
} // writeDate