// ********* ********* ********* ********* ********* ********* ********* ********* *********
// Special Event function
// This function allows you set events for every weekday or for holidays
//
// VARIABLE			DATA TYPE	DESCRIPTION
// y				number		the 4-digit year (i.e. 2002)
// m				number		the month (1=jan, 2=feb,... 12=dec)
// d				number		the day
// dte				date		the full date
// intWeekday			number		day of the week (0=sun; 1=mon; 2=tue, ..., 6=sat)
// intWeekOfYear		number		week number of the year
// intWeekOfMonth		number		week number of month (1st Sunday, 2nd Sunday, ...)
// blnLast			boolean		is this the Last Weekday of the month
// dteEaster			date		the full date of Easter Sunday for the year
// dteMardiGras			date		the full date of Mardi Gras Tuesday for the year
// dteAshWednesday		date		the full date of Ash Wednesday for the year
// dteGoodFriday		date		the full date of Good Friday for the year
// ********* ********* ********* ********* ********* ********* ********* ********* *********
function scSpecialEvent(dte) {
	var objEvent;
	var arrEvents = new Array();
	var dteCurrent = new Date();
	
	var m = dte.getMonth() + 1;
	var d = dte.getDate();
	var y = dte.getFullYear();
	var intWeekday = dte.getDay();
	var intWeekOfYear = dte.weekOfYear();
	var intWeekOfMonth = dte.weekOfMonth();

	var intLastMonth = new Date(y, m-1, d+7).getMonth();
	if (intLastMonth == 0) intLastMonth = 12;
	var blnLast = ( intLastMonth == m );

	var dteEaster = fscEaster(y);
	var dteMardiGras = dteEaster.add("d", -47);
	var dteAshWednesday = dteEaster.add("d", -46);
	var dteGoodFriday = dteEaster.add("d", -2);

	// ********* ********* ********* ********* ********* ********* ********* *********
	// *** current date
	// ********* ********* ********* ********* ********* ********* ********* *********

	// *** current day event
	//if ( dte.equalsTo(dteCurrent) ) {
	//	objEvent = new EventObj(m,d,y, "TODAY", null, "scToday");
	//	arrEvents[arrEvents.length] = objEvent;
	//};
	
	// ********* ********* ********* ********* ********* ********* ********* *********
	// *** every weekday functions
	// ********* ********* ********* ********* ********* ********* ********* *********

	// every sunday
	//if (intWeekday==0) {
		//objEvent = new EventObj(m,d,y, "every sunday", null, "scEventBlue");
		//arrEvents[arrEvents.length] = objEvent;
	//};
	
	// every 2nd saturday 
	//if (intWeekday==6 && (intWeekOfMonth==1 || intWeekOfMonth==3) ) {
		//objEvent = new EventObj(m,d,y, "1st and 3rd saturday", null, "scEventPurple");
		//arrEvents[arrEvents.length] = objEvent;
	//};

	// ********* ********* ********* ********* ********* ********* ********* *********
		
	return arrEvents;
};






