// this is the default language ID to use for the template if 
// the language of the page cannot be determined
var templateLangID = "en";


// ================================================


// ================================================
// gov_showHeader() 
// - the top table header output 
// - if print version is selected, then only shows
//   the printer header image
// ================================================
function gov_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



	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 

		html += "<a href=\"http://www.gov.mb.ca/index.html\" id=\"logo\" accesskey=\"1\" title=\"Government of Manitoba\"><img src=\""+resourcePath+"images/mb_logo.jpg\" width=\"190\" height=\"134\" alt=\"Government of Manitoba\" /></a>\n";
		html += "<ul id=\"navbar\">\n";
		html += "	<li><a href=\"http://www.gov.mb.ca/government/index.html\"><img src=\""+resourcePath+"images/nav/government.gif\" width=\"107\" height=\"43\" alt=\"Government\"/></a></li>\n";
		html += "	<li><a href=\"http://www.gov.mb.ca/business/index.html\"><img src=\""+resourcePath+"images/nav/business.gif\" width=\"75\" height=\"43\" alt=\"Business\"/></a></li>\n";
		html += "	<li><a href=\"http://www.gov.mb.ca/residents/index.html\"><img src=\""+resourcePath+"images/nav/residents.gif\" width=\"77\" height=\"43\" alt=\"Residents\"/></a></li>\n";
		html += "	<li><a href=\"http://www.gov.mb.ca/tourism/index.html\"><img src=\""+resourcePath+"images/nav/tourism.gif\" width=\"72\" height=\"43\" alt=\"Tourism\"/></a></li>\n";
		html += "	<li><a href=\"http://www.gov.mb.ca/services/index.html\"><img src=\""+resourcePath+"images/nav/services.gif\" width=\"80\" height=\"43\" alt=\"Services\"/></a></li>\n";
		html += "	<li id=\"search\">\n";
		html += "		<form name=\"gs\" method=\"GET\" action=\"http://discovery.gov.mb.ca/search\">\n";
		html += "		<a name=\"search\"></a><label for=\"topsearchbox\" title=\"Enter Search Criteria\"></label><input name=\"q\" type=\"text\" id=\"topsearchbox\" class=\"searchbox\" value=\"Search...\" size=\"15\" onfocus=\"if (this.value == 'Search...') this.value = '';\" title=\"Enter Search Text\" alt=\"Enter Search Text\" />\n";
		html += "		<input type=\"image\" src=\""+resourcePath+"images/header_button_go.jpg\" alt=\"Begin Search\" title=\"Begin Search\" />\n";
		html += "		<input type=\"hidden\" name=\"entqr\" value=\"0\" />\n";
		html += "		<input type=\"hidden\" name=\"output\" value=\"xml_no_dtd\" />\n";
		html += "		<input type=\"hidden\" name=\"sort\" value=\"date:D:L:d1\" />\n";
		html += "		<input type=\"hidden\" name=\"ud\" value=\"1\" />\n";
		html += "		<input type=\"hidden\" name=\"client\" value=\""+resourceSearch_client+"\">\n";
		html += "		<input type=\"hidden\" name=\"oe\" value=\"UTF-8\">\n";
		html += "		<input type=\"hidden\" name=\"ie\" value=\"UTF-8\">\n";
		html += "		<input type=\"hidden\" name=\"proxystylesheet\" value=\""+resourceSearch_proxystylesheet+"\">\n";
		html += "		<input type=\"hidden\" name=\"site\" value=\""+resourceSearch_site+"\">\n";
		html += "		</form>\n";
		html += "	</li>\n";
		html += "</ul>";
	}
}

// ================================================
// gov_showFooter()
// - displays the bottom table of text links
// ================================================
function gov_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



	var html = "\n";
	var obj = document.getElementById("footer");
	if (obj) {
		html += "<ul class=\"nav\">\n";
		html += "	<li class=\"government\"><a href=\"http://www.mhhc.mb.ca/index.html\">Home</a></li>\n";
		html += "	<li class=\"business\"><a href=\"http://www.mhhc.mb.ca/info/index.html\">Mandate/Objectives</a></li>\n";
		html += "	<li class=\"residents\"><a href=\"http://www.mhhc.mb.ca/info/history.html\">History</a></li>\n";
		html += "	<li class=\"tourism\"><a href=\"https://ssl.mhhc.mb.ca/showLogon.do\">Employees</a></li>\n";
		html += "	<li class=\"services\"><a href=\"http://www.mhhc.mb.ca/contact/index.html\">Contact Us</a></li>\n";
		html += "</ul>\n";
		html += "<div id=\"links\">\n";
		
		


		
		html += "</div>\n";


		obj.innerHTML = html;
	}
}










// =================================================================
// gov_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 
//   gov_setupPage() in the OnLoad() Event
// =================================================================
function gov_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"}));
};

}
