function clickFeatureThumb(num) {
	setFeature(num);
	clearTimeout(timer);
}

function setFeature(num) {
	thisFeature = num;
	var sel_y = new Array(19,82,145,208,270,332)
	sel = document.getElementById("feature_selector");
	title = document.getElementById("feature_title");
	sel.style.top = sel_y[num]+11;
	document.images["feature_pic_jpg"].src = content[num][0];
	updateContent("feature_title","<a href='#' onClick='gotoFeature(thisFeature); return false'>"+content[num][1]+"</a>");
	updateContent("feature_copy",content[num][2]+" <a href='#' onClick='gotoFeature(thisFeature); return false'>more >></a>");
}

function nextFeature() {
	thisFeature++;
//	alert(thisFeature);
	if (thisFeature >= content.length) thisFeature = 0;
	setFeature(thisFeature);
	timer = setTimeout("nextFeature()",delay);
}

function gotoFeature(num) {
//	alert(content[num][3]);
	document.location.href = content[num][3];
}

function updateContent(elementid,content){
	var main_content = document.getElementById(elementid);		
	main_content.innerHTML = content;
}	

function updateContent2(elementid,content){
	if (document.all)
		elementid.innerHTML=content;
	else if (document.getElementById){
		rng = document.createRange();
		el = document.getElementById(elementid);
		rng.setStartBefore(el);
		htmlFrag = rng.createContextualFragment(content);
		while (el.hasChildNodes()) el.removeChild(el.lastChild);
		el.appendChild(htmlFrag);
	}
}


