	function resizeCLT(adHandle) {
//		ugcCltHeight = readCookie('ugcCltHeight');
//		if(adHandle != null && ugcCltHeight != null) adHandle.height = ugcCltHeight;
	}

/*
 *	Input:
 *		functionName	the name a function registers itself as in the AjaxManager
 *		divid			the id of a div the results of hte above function should be plugged into
 *		params			paramters for the called function in this format:  {paramName:paramValue, otherParam:anotherValue, etcParam:etcValue}
 *	
 *	Output:
 *		When the AJAX call returns the div iwht id=divid will have its content replaced with the returned html
 */
function executeAjaxFunction(functionName, divid, params) {
	if(params == undefined || params == null) params = Array();
	params['ajaxaction'] = functionName;

	new Ajax.Request('http://'+http_host+'/ajax-manager.php',
	  {
		method:'post',
		parameters: params,
		onSuccess: function (transport) {
			var response = transport.responseText || "no response text";
			//alert(response);
			var div = document.getElementById(divid);
			if(div != undefined && div != null) {
				div.innerHTML = transport.responseText;
			}
		},
		onFailure: function () { 
		}


	  });
}

function executeAjaxFunctionXML(functionName, successfunction, params) {
	if (params == undefined || params == null) params = new Array();
	//params['ajaxaction'] = functionName;
		param = new Array();
			param['name'] = 'ajaxaction';
			param['value'] = functionName;
	params[params.length] = param;

	var paramString = '';
	for(var i=0; i<params.length; i++) {
		paramString += '&'+params[i].name+'='+params[i].value;
	}

	if(successfunction == undefined || successfunction == null) successfunction = defaultAjaxSuccessFunction;

	new Ajax.Request('http://'+http_host+'/ajax-manager.php',
	{
		method:'post',
		parameters: paramString,
		onSuccess: function (transport) {
					var response = transport.responseText || "<error></error>";
					successfunction(response);
				},
		onFailure: function () { 
		}
	});
}

function defaultAjaxSuccessFunction(xml) {}

function showValidationError(errorText) {
	if (errorText=="" || errorText==null) errorText="There was an error, please try again."

	var html='';
	html+='<div id="validationError_container">\n';
		html+='<div id="modal_globalClose"><a href="#" onClick="closeModalWindow();return false;" class="smallYellow">CLOSE<img src="<? print UGC_GLOBAL_IMAGE_PATH ?>minus.gif" width="10" height="9" /></a></div>\n';
		html+='<div id="modal_body">\n';
			html+='<div id="validationError_errorText_heading">Error:</div>\n';
			html+='<div id="validationError_errorText">'+errorText+'</div>\n';
			html+='<div class="modal_center"><div class="button_container"><a href="" onClick="closeModalWindow();return false;" class="button">CLOSE</a></div></div>\n';
		html+='</div>\n';
	html+='</div>\n';
	html+='<div id="validationError_container_hook" style="display: none"><a href="#validationError_container" id="modal_link_validationError">hidden modal window</a></div>\n';

	$('validationError_container_global').update(html);
	modalWindow_validationError = new Control.Modal('modal_link_validationError', { opacity: 0.5, width: 450, height: 180, fade: false, containerClassName: 'modal_container_validationError', overlayClassName: 'modal_overlay_validationError', afterClose: function(){cleanUpValidationError();}});
	modalWindow_validationError.open();
}

function cleanUpValidationError() {
	$('validationError_container_global').update();
}

function forceBreak(n) {
	var u, r, c, x;
	if (n.nodeType == 3) {
		u = n.data.search(/\S{50}/);
		if(u >= 0) {
			r = n.splitText(u + 35);
			n.parentNode.insertBefore(document.createElement('WBR'), r);
		}
	} else if (n.tagName != 'STYLE' && n.tagName != 'SCRIPT' && n.tagName != 'PRE') {
		for (c = 0; x = n.childNodes[c]; ++c) {
			forceBreak(x);
		}
	}
}

var itAnswersLandingPageTagCloud = 'a';
function toggleITAnswersLandingPageTagCloud() {
	var hideDiv = itAnswersLandingPageTagCloud;
	itAnswersLandingPageTagCloud = ('a'==itAnswersLandingPageTagCloud)?"b":"a";

	document.getElementById('tagcloud_'+hideDiv).style.display="none";
	document.getElementById('tagcloud_'+itAnswersLandingPageTagCloud).style.display="block";
}