function listCities(cit)
{
	showCities(cit);
	showPhone();
	getCodes(document.my_form.member_mobile.value);
}

function showCities(cit)
{
	if($('country_location').value) var vCountry = $('country_location').value;
	else var vCountry = document.getElementById('country_location').options(document.getElementById('country_location').selectedIndex).innerText; 
	
	document.getElementById('slctioN').innerHTML = 'انتظر قليلاً';
	new Ajax.Updater('slctioN', 'ajax.php?do=countries&country='+vCountry+'&city='+cit,
	  {
		method:'post',
			onSuccess: function(transport){
		  var response = transport.responseText || "no response text";
		},
		onFailure: function(){ alert('خطأ في جلب البيانات...') }
	  });
}

function getCodes(numm)
{
	if($('country_location').value) var vCountry = $('country_location').value;
	else var vCountry = document.getElementById('country_location').options(document.getElementById('country_location').selectedIndex).innerText; 

	new Ajax.Updater('phone', 'ajax.php?do=codes&country='+vCountry+'&numm='+numm,
	  {
		method:'post',
			onSuccess: function(transport){
		  var response = transport.responseText || "no response text";
		},
		onFailure: function(){ alert('خطأ في جلب البيانات...') }
	  });
}


function showPhone()
{
	
	if($('country_location').value) var vCountry = $('country_location').value;
	else var vCountry = document.getElementById('country_location').options(document.getElementById('country_location').selectedIndex).innerText; 

	document.getElementById('phone_number').innerHTML = 'انتظر قليلاً';
	new Ajax.Updater('phone_number', 'ajax.php?do=phones&country='+vCountry,
	  {
		method:'post',
			onSuccess: function(transport){
		  var response = transport.responseText || "no response text";
		},
		onFailure: function(){ alert('خطأ في جلب البيانات...') }
	  });
}

