function scrollToID(id){
	var scroll = new Fx.Scroll('scroller', {
			wait: false,
			duration: 1500,
			transition: Fx.Transitions.Quad.easeInOut
	});
	scroll.toElement('item'+id);
};

function changeSubNav(section,catid,id){
	  var ajax = new Ajax('scripts/'+section+'-nav-get.php?id='+ id +'&catid='+catid, {
		method: 'get',
		update: 'olSubNav',
		evalScripts: false,
		onComplete: function() {
			changePageContent(section,catid,id);
		}
	
	  });
	  ajax.request();
	  return false;	
};

function changePageContent(section,catid,id){
	//change the content
	  var ajax = new Ajax('scripts/'+section+'-content-get.php?id='+ id +'&catid='+catid, {
		method: 'get',
		update: 'scroller',
		evalScripts: false,
		onComplete: function() {
			changeTitle(section,catid,id);
		}
	  });
	  ajax.request();
	   
	  return false;
	  
	  
};

function changeTitle(section,catid,id){
	//change the content
	  var ajax = new Ajax('scripts/title-get.php?id='+ id +'&catid='+catid+'&sec='+section, {
		method: 'get',
		update: 'titleContent',
		evalScripts: false,
		onComplete: function() {
			
			changePlayer(section,catid,id);
		}
	  });
	  ajax.request();
	  scrollToID(id);
	  return false;
};

function changePlayer(section,catid,id){
	//change the content
	  var ajax = new Ajax('scripts/player-get.php?id='+ id +'&catid='+catid+'&sec='+section, {
		method: 'get',
		update: 'podPlayer',
		evalScripts: false
	  });
	  ajax.request();
	  return false;
};
	evalScripts: false
	  });
	  ajax.request();
	  return false;
};
