function MM_MatchReport(url){	window.open(url, "reportwindow","scrollbars=1, resizable=1, menubar=1, width=900");}function MM_PlayerInfo(url){	window.open(url, "playerwindow","scrollbars=1, resizable=1, menubar=1, width=500, height=600");}function MM_Export(url){	window.open(url, "playerwindow","scrollbars=1, resizable=1, menubar=1, width=900, height=900");}function MM_Enroll(url){	window.open(url, "enrollwindow","scrollbars=1, resizable=1, menubar=1, width=900, height=900");}function MM_Help(page){	window.open("Help.asp?Page=" + page, "helpwindow","scrollbars=1, resizable=1, menubar=1, width=900, height=900");}function MM_Calendar(thisObj, objName, cName)
{
if(cName != null) scwNextAction=MM_Changed.runsAfterSCW(thisObj,cName);
scwShow(document.getElementById(objName),thisObj);
}
function MM_CalendarAge(thisObj, objName, cName)
{
if(cName != null) scwNextAction=MM_Changed.runsAfterSCW(thisObj,cName);
scwDropDownYears = 60;scwBaseYear = scwDateNow.getFullYear()- scwDropDownYears + 4;
scwShow(document.getElementById(objName),thisObj);
}
function MM_CheckDate(thisObj, objName)
{
var dt = scwInputFormat(thisObj.value);
if (dt[0] == null) thisObj.value = "";
}
function UpdateOptions(){	UpdateClubOptions();}function UpdateClubOptions(){	var objs = document.getElementsByTagName("select");	for (var i = 0; i < objs.length; i++)	{		var o = objs[i];		try		{			if (o.name.indexOf("ClubID") >= 0)			{				if (o.selectedIndex >= 0)				{					var clubID = o.options[o.selectedIndex].value;					o.options[o.selectedIndex] = null;					for (var count = 0; count < clubs.length; count += 2)					{						var x = new Option(clubs[count], clubs[count+1]);						if (clubs[count+1] == clubID)							x.selected = true;						o.options.add(x);					}					o.value = clubID;				}			}		}		catch (e)		{		}	}}var xmlHttp1 = false;var MM_Request_Body = "";var MM_Request_Url = "";function StateChanged() {	if (xmlHttp1 !== null && (xmlHttp1.readyState==4 || xmlHttp1.readyState=="complete"))	{		//var obj1 = document.getElementById("OffenderClubID");		//alert(obj1.innerHTML);//	alert(xmlHttp1.readyState + "<br/> " + xmlHttp1.responseText);		document.body.style.cursor = "default";		var resp = xmlHttp1.responseText;		var obj = document.getElementById(MM_Request_Body);		if (resp == "BadID.htm")
		{
			window.location.href = "BadID.htm";
			return;
		}
		xmlHttp1 = null;		MM_Request_Url = "";		try		{			obj.innerHTML = resp;			UpdateOptions();			if (resp.substring(0, 10) == 'Import.asp' || resp.substring(0, 10) == 'Import.php')			{				var i = resp.indexOf("<",0);				if (i > 0)					resp = resp.substring(0, i);				MM_Request(resp, MM_Request_Body);			}		}		catch (e)		{			alert(e.message);			obj.innerHTML="";		}		//alert(obj1.innerHTML);	}}function QuickStateChanged() {	if (xmlHttp1 !== null && (xmlHttp1.readyState==4 || xmlHttp1.readyState=="complete"))	{		document.body.style.cursor = "default";		var resp = xmlHttp1.responseText;		//alert(xmlHttp1.responseText);
		if (resp == "BadID.htm")
		{
			window.location.href = "BadID.htm";
			return;
		}
		var obj = document.getElementById(MM_Request_Body);		xmlHttp1 = null;		MM_Request_Url = "";		try		{			obj.innerHTML = resp;		}		catch (e)		{			alert(e.message);			obj.innerHTML="";		}	}}function GetXmlHttpObject(handler){ 	var objXmlHttp=null;	if (window.XMLHttpRequest)	{		// Mozilla, Safari,...		objXmlHttp=new XMLHttpRequest();		objXmlHttp.onload=handler;		objXmlHttp.onerror=handler;		objXmlHttp.onreadystatechange=handler;		return objXmlHttp;	}	else if (window.ActiveXObject)	{		// IE		try		{			objXmlHttp = new ActiveXObject("Msxml2.XMLHTTP");			objXmlHttp.onreadystatechange=handler;			return objXmlHttp;		}		catch (e)		{			try			{				http_request = new ActiveXObject("Microsoft.XMLHTTP");				objXmlHttp.onreadystatechange=handler;				return objXmlHttp;			}			catch(e)			{ 				alert("Error. Scripting for ActiveX might be disabled");				return objXmlHttp;			}		}	}	alert('Cannot create XMLHTTP instance');	return objXmlHttp;}function MM_Restart(){	if (MM_Request_Url != "")	{		xmlHttp1 = null;		var obj = document.getElementById(MM_Request_Body);		try		{			obj.innerHTML = MM_Request_Url;		}		catch (e)		{		}		MM_Request(MM_Request_Url + "&Restart=1", MM_Request_Body);	}}function MM_Request(url, divName){	MM_Request_Body = divName;	if (MM_Request_Body == undefined || MM_Request_Body == "")		MM_Request_Body = "BodyData";	xmlHttp1=GetXmlHttpObject(StateChanged);	try	{		//var obj = document.getElementById(MM_Request_Body);		var obj = document.getElementById(MM_Request_Body);		document.body.style.cursor = "wait";		MM_Request_Url = url;		xmlHttp1.open("GET", url, true);		xmlHttp1.send(null);		var objs = obj.getElementsByTagName("input");		for (var i = 0; i < objs.length; i++)			objs[i].disabled=true;		objs = obj.getElementsByTagName("select");		for (var i = 0; i < objs.length; i++)			objs[i].disabled=true;		return;	}	catch (e)	{		//alert(e.message);	}	document.getElementById(MM_Request_Body).innerHTML="Cannot get Url: " + url;	document.body.style.cursor = "default";	xmlHttp1 = null;}function MM_QuickRequest(url, divName){	MM_Request_Body = divName;	if (MM_Request_Body == undefined || MM_Request_Body == "")		MM_Request_Body = "BodyData";	xmlHttp1=GetXmlHttpObject(QuickStateChanged);	try	{		//var obj = document.getElementById(MM_Request_Body);		var obj = document.getElementById(MM_Request_Body);		document.body.style.cursor = "wait";		MM_Request_Url = url;		xmlHttp1.open("GET", url, true);		xmlHttp1.send(null);		return;	}	catch (e)	{		//alert(e.message);	}	document.getElementById(MM_Request_Body).innerHTML="Cannot get Url: " + url;	document.body.style.cursor = "default";	xmlHttp1 = null;}
