var objDoc;
var SOURCE="http://www.pokerstars.net/league-data/prohibited_software/prohib_hu.xml";
//var SOURCE="prohib.xml";

function CreateXMLDoc(strSourceDoc)
{
	var obj;
	
	if (window.ActiveXObject)
	{// code for IE
		obj=new ActiveXObject("Microsoft.XMLDOM");
		obj.async=false;
		obj.load(strSourceDoc);
	}//endif
	else 
	{
		try //Firefox, Mozilla, Opera, etc.
		{
		  obj=document.implementation.createDocument("","",null);
		  obj.async=false;
		  obj.load(strSourceDoc);
		}
		catch(e)
		{ 
			try //Google Chrome
			{
			   var xmlhttp = new window.XMLHttpRequest();
			   xmlhttp.open("GET",strSourceDoc,false);
			   xmlhttp.send(null);
			   obj = xmlhttp.responseXML.documentElement;
			}
			catch(e)
			{
			   error=e.message;
			}
		}
	}
	return obj;
}


function SetListText(obj, strElement)
{
		var objElem=obj.getElementsByTagName(strElement);
		document.write("<ol>");
		for (var i=0;i<objElem.length;i++)
		{ 
			document.write("<li class=\"sub_nav\">");
			document.write(objElem[i].getElementsByTagName("name")[0].childNodes[0].nodeValue);
			document.write("</li>");
		}  
		document.write("</ol>");
} 


function permittedSoft()
{
	if(objDoc==null) objDoc=CreateXMLDoc(SOURCE);
	SetListText(objDoc,"permitted");
}


function prohibitedSoft()
{
	if(objDoc==null) objDoc=CreateXMLDoc(SOURCE);
	SetListText(objDoc,"prohibited");
}


function semiPermitted()
{
	if(objDoc==null) objDoc=CreateXMLDoc(SOURCE);
	SetListText(objDoc,"semi");
}


function printDate(language)
{
	if(objDoc==null) objDoc=CreateXMLDoc(SOURCE);

	var objElem=objDoc.getElementsByTagName("date");

	for (var j=0;j<objElem.length;j++)
	{
		document.write(objElem[j].getElementsByTagName(language)[0].childNodes[0].nodeValue);
	}//endfor
	document.write("</p>");
	
}//end function
//===================================================


