// this is the default language ID to use for the template if 
// the language of the page cannot be determined
var templateLangID = "en";


// ================================================


// ================================================
// showHeader() 
// - the top table header output 
// - if print version is selected, then only shows
//   the printer header image
// ================================================
function showHeader() {

	// set the default values for the google search box
	// if the calling web page has not set these values, it will go to the default search results template
	if (!isDefined(window.resourceSearch_client)) {
		resourceSearch_client = "";
	}
	if (!isDefined(window.resourceSearch_proxystylesheet)) {
		resourceSearch_proxystylesheet = "";
	}
	if (!isDefined(window.resourceSearch_site)) {
		resourceSearch_site = "";
	}

	if (resourceSearch_client == "") {
		resourceSearch_client = "manitoba";
	}
	if (resourceSearch_proxystylesheet == "") {
		resourceSearch_proxystylesheet = "manitoba";
	}
	if (resourceSearch_site == "") {
		resourceSearch_site = "default_collection";
	}


	var html = "";
	var obj = document.getElementById("header");
	if (obj) {
	
		if (tempURL.indexOf("?print") > -1 || tempURL.indexOf("#printerfriendly") > -1) {
			html += '<div align="center" style="margin-left:-20px;"><img src="'+resourcePath+'images/printer_header.jpg"></div>';
		} else {
		}

		obj.innerHTML = html;
	}
}

// ================================================
// showFooter()
// - displays the bottom table of text links
// ================================================
function showFooter() {

	// set the default values for the google search box
	// if the calling web page has not set these values, it will go to the default search results template
	if (!isDefined(window.resourceSearch_client)) {
		resourceSearch_client = "";
	}
	if (!isDefined(window.resourceSearch_proxystylesheet)) {
		resourceSearch_proxystylesheet = "";
	}
	if (!isDefined(window.resourceSearch_site)) {
		resourceSearch_site = "";
	}

	if (resourceSearch_client == "") {
		resourceSearch_client = "manitoba";
	}
	if (resourceSearch_proxystylesheet == "") {
		resourceSearch_proxystylesheet = "manitoba";
	}
	if (resourceSearch_site == "") {
		resourceSearch_site = "default_collection";
	}


	var html = "\n";
	var obj = document.getElementById("footer");
	if (obj) {
		html += "";


		obj.innerHTML = html;
	}
}










// =================================================================
// replaceIFR()
// - replaces elements with Inman Flash Replacement SWFs
// - if you have more elements to replace, then create a javascript 
//   function in your web page header call it before 
//   setupPage() in the OnLoad() Event
// =================================================================
function replaceIFR() {

/* Replacement calls. Please see documentation for more information. */
if(typeof sIFR == "function"){
	sIFR.replaceElement(named({sSelector:"div#banners ul li", sFlashSrc:resourcePath+"swf/banner_ifr.swf", sWmode:"transparent", sFlashVars:"", sWidth:"207", sHeight:"60"}));
	sIFR.replaceElement(named({sSelector:"#organization", sFlashSrc:resourcePath+"swf/title_ifr.swf", sWmode:"transparent",sFlashVars:"", sWidth:"620", sHeight:"38"}));
	sIFR.replaceElement(named({sSelector:"#menuheading", sFlashSrc:resourcePath+"swf/above_sidemenu_ifr.swf", sWmode:"transparent",sFlashVars:"", sWidth:"189", sHeight:"60"}));
};

}