/********************************************************************************
 *	Copyright (C) 2003 Magna Entertainment Corp.
 *
 *	FileName:		CorporateScripts_Functions.js
 *	Author:			Dylan Pope
 *	Incept:			13 October 2003
 *	Description:	This file contains ECMAScript functions for use by the MEC
 *					CMS solution.
 *	-----------------------------------------------------------------------------
 *	Edit History:
 *	ID		Date		Author		Description
 *	=============================================================================
 *	(a)
 ********************************************************************************/

// Formats and returns today's date
function GetTodayText()
{
	var_date = new Date();
	date = var_date.getDate();
	month = var_date.getMonth();
	year = var_date.getYear();

	if (month == 0) {
		month = "January"
	}
	else if (month == 1) {
		month = "February"
	}
	else if (month == 2) {
		month = "March"
	}
	else if (month == 3) {
		month = "April"
	}
	else if (month == 4) {
		month = "May"
	}
	else if (month == 5) {
		month = "June"
	}
	else if (month == 6) {
		month = "July"
	}
	else if (month == 7) {
		month = "August"
	}
	else if (month == 8) {
		month = "September"
	}
	else if (month == 9) {
		month = "October"
	}
	else if (month == 10) {
		month = "November"
	}
	else if (month == 11) {
		month = "December"
	}
	if (year == 099) {
		year = "1999"
	}
	else if (year == 100) {
		year = "2000"
	}
	else if (year == 101) {
		year = "2001"
	}
	else if (year == 102) {
		year = "2002"
	}
	else if (year == 103) {
		year = "2003"
	}
	else if (year == 104) {
		year = "2004"
	}
	
	//document.write(month + " " + date + ", "  + year);
	var todayText = month + " " + date + ", "  + year;
	return todayText;
} 
