
//----------- ajax stuff to dynamically load quotes

	function quoteCallback(responseText) {
		$('quoteBox').innerHTML = responseText;
		setDocTitle();
	}

function setDocTitle() {
	document.title = $('qTitleX').innerHTML + " - Andrew Cohen Quote of the Week";
	
	// and the emailFriend link
	$('emailFriendLink').href = '../misc/email-friend.asp?quoteID=' + $('qIDX').innerHTML;
}

function loadQuote(id) {	// omit ID for the most recent
	var parms = ("id="+ (id ? id : getQueryParam("quote"))),
		a = new SimpleAjax( "_quoteServer.asp", parms, quoteCallback);
	return false;
}

//----------- quote browser

// (requires slider.js)
//
var sliderObj;

function initSlider() {
	sliderObj = new SlidingPane('quoteArchive');
	sliderObj.init();
	sliderObj.prepPager(220,15);
}
