function GetCities(State)
{

	if(document.getElementById("loading_status")!= null){
		document.getElementById("loading_status").innerHTML = "<img src=images/progress-bar-dots.gif>";
	}
	if(window.XMLHttpRequest)
	{
		oRequest = new XMLHttpRequest();
	}
	else if(window.ActiveXObject)
	{
		oRequest = new ActiveXObject("Microsoft.XMLHTTP");
	}

	oRequest.open("POST", "GetCitylistPrayerTime.asp", true);
	oRequest.onreadystatechange = UpdateCityList;

	oRequest.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
	oRequest.send("strState=" + escape(State));
}

function UpdateCityList()
{
	if(oRequest.readyState == 4)
	{
	if(oRequest.status == 200)
	{
		var City = oRequest.responseText;
		var CityBox = document.getElementById("City");

	              CityBox.options.length = 0;

	                if(City != "")
              	  {
                    		var arrCity = City.split(",");
                   	CityBox.options[CityBox.options.length] = new Option("Select a city");
                   		 for(i = 0; i < arrCity.length; i=i+2)
                    		{
		                        if(arrCity[i] != "")
                        		          {
		                            CityBox.options[CityBox.options.length] = new Option(arrCity[i], arrCity[i+1]);

		                        }
                    		}
					}
		 if(document.getElementById("loading_status")!= null){
		document.getElementById("loading_status").innerHTML = "";
		 }
	}
	else
	{
		document.getElementById("Error").innerHTML = "Asychronous Error";
	}
	}
	//document.body.style.cursor = 'default';
}