function setValues(num){
	var theTitle = $j('#lsTitle' + num).text();
	var theTeaser = $j('#lsTeaser' + num).text();
	var theImage = $j('#lsImage' + num).text();
	var theURL = $j('#lsURL' + num).text();
	var theDesc = $j('#lsDesc' + num).text();
	clearHomeNavTimer();
	num = (num == null) ? counter : num;
	counter = num;

//		alert(theTitle + '\n' + theTeaser + '\n' + theImage + '\n' + theURL + '\n' + theDesc);
//		alert($j('.theImage').attr('style'));
	
	$j('.theImage').attr('style', 'background-image:url(/images/lifeStyle/' + theImage + ')');
	$j('.theCopy > h2').html(theTitle);

	if(theDesc.length > 0) { 
		$j('.theCopy > p').html(theTeaser + ' <a href="' + theURL + '">Read More &raquo;</a>');

//		$j('.theCopy > p').html(theTeaser + ' <a href="lifestyle.cfm?lifID=#lifID#">Read More &raquo;</a>');
	} else {
		$j('.theCopy > p').html(theTeaser);
	}

	$j('.myTab').removeClass('tab-over');
	$j('.myTab#' + num).addClass('tab-over');
}

var counter = 1;
var homeNavTimer = null;
var restartNavTimer = null;

function setHomeNavTimer(){
	var nextTab = (counter >= 4) ? 1 : eval(counter)+1;
	clearHomeNavTimer();
	//alert(nextTab);
	homeNavTimer = setTimeout('setValues(' + nextTab + ');setHomeNavTimer();', 5000);
}

function clearHomeNavTimer(){
	if (restartNavTimer != null) clearTimeout(restartNavTimer);
	if (homeNavTimer != null) clearTimeout(homeNavTimer);
}
	

