function getPage(URL, DIV_ID) {

  var ajax = new Ajax.Updater({success: DIV_ID}, URL, {method: 'get', parameters:'', onFailure: reportError,evalScripts: true});

}

//----------------------------------------------------------------------------------------------

//----------------------------------------------------------------------------------------------

//----------------------------------------------------------------------------------------------



function AJAX_getDIV(URL, DIV_ID) {

	

  var ajax = new Ajax.Updater({success: DIV_ID}, URL, {method: 'get', parameters:'', onFailure: reportError,evalScripts: true});

}





function ajaxGet(URL, DIV_ID) {

	

  var ajax = new Ajax.Updater({success: DIV_ID}, URL, {method: 'get', parameters:'', onFailure: reportError,evalScripts: true});

}



//----------------------------------------------------------------------------------------------

//----------------------------------------------------------------------------------------------

//----------------------------------------------------------------------------------------------



function reportError(request) {

	alert("onFailure was called with "+request.responseText);

//$F('errorStatus').value = "Error";

}

//-------------------------------------------------------------------------------------------

//-------------------------------------------------------------------------------------------







function ajaxPost  (returnID, url, formID) {

	var ajax = new Ajax.Updater(returnID, url, {method:'post', parameters:$(formID).serialize()} );

}





function ajaxPost_sync  (url, formID, callbackFunction) {

	var req = new Ajax.Request(url,

		{

			method:'post',

			onSuccess : callbackFunction,

			onFailure : reportError,

			parameters:$(formID).serialize()

		});


}







function ajaxGet_sync  (url, callbackFunction) {

	var req = new Ajax.Request(url,

		{

			method:'get',

			onSuccess : callbackFunction,

			onFailure : reportError

		});

	

}



var ajaxGetResponseValue = function(needle, haystack) {



	

	openTag_position  = haystack.indexOf(needle);

	startValue_position =  openTag_position + needle.length;



	

	closeTag_position  = haystack.indexOf("</"+needle);

	

	lengthOfValue = closeTag_position - startValue_position ;

	value = haystack.substr(startValue_position+1,lengthOfValue-1);

	return value;

	

}