function getPage(pageno, totalPages){
	for (var i=1;i<=totalPages;i++){
		if (pageno==i){
			document.getElementById("page" + i).style.zIndex = 2;
			document.getElementById("num_top_"+ i).style.fontWeight = "bold";
			document.getElementById("num_bottom_"+ i).style.fontWeight = "bold";
		}
		else{
			document.getElementById("page" + i).style.zIndex = -1;
			document.getElementById("num_top_"+ i).style.fontWeight = "normal";
			document.getElementById("num_bottom_"+ i).style.fontWeight = "normal";
		}
	}
	//window.location.hash = "top";
}

function updateMainImage(mediumImage, highresImage, curNo, numImages){
	MM_swapImage('mainimage','',mediumImage,1);
	document.getElementById('high_res_link').href=highresImage;
	
	for (var i=0;i<numImages;i++){
		document.getElementById("image"+i).style.border='1px solid #dddddd';
	}
	document.getElementById("image"+curNo).style.border='1px solid #666666';
	
}

function rolloverBorder(curHighRes, curNo){
	var newHighRes = curHighRes.replace("..", "");
	if (document.getElementById('high_res_link').href.indexOf(newHighRes)==-1) document.getElementById("image"+curNo).style.border='1px solid #dddddd';
}

$(document).ready(function() {
	
	$.localScroll();
});