// Necessary Js for all page on this website
/*
	Declare Global Variables
	on Load 
		Initialise for Prettyphoto
		set the Left Menu Height, 
		Reset Search Highlight
		Search Textbox OnKeyup, KeyPress 	-> call reset_highlight
		Search Submit 						-> call submitSearchForm
	
	Other Functions 
		submitSearchForm()					-> Submit SearchForm
		submitContactForm()					-> Submit ContactForm
		showform()							-> Show Div
		hideform()							-> Hide Div	
*/

// Global Variables 
var globalErr 			= 1;  // Contact Form Validation 
var SearchType 			= "partial"; //exact, whole, partial - Search method
//var searchDisplayType  	= "newpage"; // overlay =  below search textbox , newpage = on to the same page
var searchDisplayDivId = (searchDisplayType	=="overlay")?"search_dropdown":"content";//search_dropdown = overlay below search textbox , content = same page

var pager1 = new Pager('overlaySearchResultId', 3); // initialize, the Overlay Search Pagination

jQuery(document).ready(function() 
{
	
	// getting the header image fade effect
	if(document.getElementById("header_images"))
	{
		if(jQuery("#header_images img").length>1)
		{
			jQuery('#header_images').cycle({ 
				fx:     'fade', //cover,scrollVert,uncover
			    timeout: 4000, 
			    delay:  -2000,
				speed: 3000,
			    random: true
			});
		}
	}
	
		
 });


// Show div
function showform(id)
{
	document.getElementById(id).style.display="block";
}

// Hide Div
function hideform(id)
{
	document.getElementById(id).style.display="none";
}


