
function showSelectTxt(game_id)
{
	if (game_id != "")
	{
		//document.getElementById("txtHint").innerHTML = 'Loading content - please wait';
		if(document.getElementById("txtPriceList"))
		{
			document.getElementById("txtPriceList").innerHTML='';
		}
		document.getElementById("txtHint").innerHTML='<img src="/site_media/images/ajax-loader.gif"/><br>';
		//<img src="/site_media/images/ajax-loader.gif"/><center>
		xmlHttp=GetXmlHttpObject();
		if (xmlHttp==null)
		{
			alert ("Browser does not support HTTP Request");
			return;
		} 

		url="/ajax_serverfaction_list/"+game_id;
		xmlHttp.onreadystatechange=statefreeorper;

		xmlHttp.open("GET",url,true);
		xmlHttp.send(null);
	}
} 

function showSelectTxt_reg(game_id)
{
	if (game_id != "")
	{
		//document.getElementById("txtHint").innerHTML = 'Loading content - please wait';
		if(document.getElementById("txtPriceList"))
		{
			document.getElementById("txtPriceList").innerHTML='';
		}
		document.getElementById("txtHint").innerHTML='<img src="/site_media/images/ajax-loader.gif"/><br>';
		//<img src="/site_media/images/ajax-loader.gif"/><center>
		xmlHttp=GetXmlHttpObject();
		if (xmlHttp==null)
		{
			alert ("Browser does not support HTTP Request");
			return;
		} 

		url="/ajax_serverfaction_list_reg/"+game_id;
		xmlHttp.onreadystatechange=statefreeorper;

		xmlHttp.open("GET",url,true);
		xmlHttp.send(null);
	}
} 


function showSelectPrice(market_id)
{
	if(market_id!="0")
	{
		//document.getElementById("txtPriceList").innerHTML = 'Loading content - please wait';
		document.getElementById("txtPriceList").innerHTML='<img src="/site_media/images/ajax-loader.gif"/><br>';
		//<img src="/site_media/images/ajax-loader.gif"/><center>
		xmlHttp=GetXmlHttpObject();
		if (xmlHttp==null)
		{
			alert ("Browser does not support HTTP Request");
			return;
		} 

		url="/ajax_prices_list/"+market_id;
		xmlHttp.onreadystatechange=statefreeorper1;

		xmlHttp.open("GET",url,true);
		xmlHttp.send(null);
	}
} 


function statefreeorper() 
{ 
	if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete")
	{ 
		document.getElementById("txtHint").innerHTML=xmlHttp.responseText;
		if(document.getElementById("txtPriceList"))
		{
			document.getElementById("txtPriceList").innerHTML='<select name="prices" class="dropdown" id="priceselect"><option value="0" selected="selected" > - Select quantity - </option></select>';
		}
	} 
}

function statefreeorper1() 
{ 
	if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete")
	{ 
		document.getElementById("txtPriceList").innerHTML=xmlHttp.responseText;
	} 
}

function GetXmlHttpObject()
{
	var xmlHttp=null;
	try
	{
	// Firefox, Opera 8.0+, Safari
	xmlHttp=new XMLHttpRequest();
	}
	catch (e)
	{
	// Internet Explorer
		try
		{
		xmlHttp=new ActiveXObject("Msxml2.XMLHTTP");
		}
		catch (e)
		{
		xmlHttp=new ActiveXObject("Microsoft.XMLHTTP");
		}
	}
return xmlHttp;
}

