// start split here
// name="description" content=""
// name="designation" content="NS"
// name="csg" content="Yes"
// name="pcg" content="Yes"
// end split here

/*
 *	Composed by: Craig Emsley
 *	Date: July 30, 2006
 *
 *	Revised by: ** YOUR NAME HERE **
 *	Date: ** MONTH DAY, YEAR REVISED **
 *
 *	---------------------------------------------------------------------------
 *
 *	These JavaScript functions provide the dropdown functionality of the
 *	menus. They are based on principle of hiding the menus when they are
 *	not wanted, and making them visible to users when they are needed.
 *
 *	-- PLACE ALL JAVASCRIPTS FOR THE MENUS IN THIS FILE! --
 *
 *	-- DO NOT EDIT THESE FUNCTIONS UNLESS: --
 *
 *     1. You are very familiar with HTML, JavaScript and CSS!
 *	   2. You are very familiar with the menu implementations!
 *	   3. You are aware of the impact any changes will have across IE, Firefox
 *	      and Netscape!
 *
 *	-- KEEP YOUR SCRIPTS CLEAN AND ORGANIZED! --
 *
 *	-- DOCUMENT YOUR SCRIPTS! --
 *
 *	** Please provide your name and the date of any revisions you make for
 *	   other programmers at the top in the format proivded.  Thank you.  
 */

// Makes the child element (elmnt1) visible to the user, while highlighting 
// the parent menu option (elmnt2).
function showmenu(elmnt1,elmnt2) {
	document.getElementById(elmnt2).style.background="#000000"
	document.getElementById(elmnt1).style.visibility="visible"
}

// Make the child element (elmnt1) invisible, and unhighlights the parent
// menu option (elmnt2)
function hidemenu(elmnt1,elmnt2,elmnt3) {
	document.getElementById(elmnt2).style.background="#336699"
	document.getElementById(elmnt1).style.visibility="hidden"
}

// Highlights "elmnt" in black
function rolloverbg(elmnt) {
	document.getElementById(elmnt).style.background="#000000"
}

// Returns "elmnt" to blue
function clearbg(elmnt) {
	document.getElementById(elmnt).style.background="#336699"
}

//
//	Special rollovers for division menu
//

var domain_name = document.URL
var counter = 0
var i = 0
for (i = 0; i < domain_name.length; i++) {
	var character = domain_name.charAt(i)	
	if (character == "/") {
		counter++		
		if (counter == 4) {		
			domain_name = domain_name.substr(0,i)			
			break;			
		}		
	}
}

// Preload all images
img1 = new Image()
img1.src = domain_name + "/intergov_relations/images/banners/cool-violet-div-bg-black.png"
img2 = new Image()
img2.src = domain_name + "/intergov_relations/images/banners/cool-violet-div-bg.png"

img3 = new Image()
img3.src = domain_name + "/intergov_relations/images/banners/emerald-div-bg-black.png"
img4 = new Image()
img4.src = domain_name + "/intergov_relations/images/banners/emerald-div-bg.png"

img5 = new Image()
img5.src = domain_name + "/intergov_relations/images/banners/copper-div-bg-black.png"
img6 = new Image()
img6.src = domain_name + "/intergov_relations/images/banners/copper-div-bg.png"

img7 = new Image()
img7.src = domain_name + "/intergov_relations/images/banners/blood-div-bg-black.png"
img8 = new Image()
img8.src = domain_name + "/intergov_relations/images/banners/blood-div-bg.png"

img9 = new Image()
img9.src = domain_name + "/uel/images/banners/grey-div-bg-black.png"
img10 = new Image()
img10.src = domain_name + "/uel/images/banners/grey-div-bg.png"

// Highlights "elmnt" in black
function rolloverbgcoolviolet() {
	document.getElementById('div1').src = img1.src 
}

// Returns "elmnt" to normal
function clearbgcoolviolet() {
	document.getElementById('div1').src = img2.src
}

// Highlights "elmnt" in black
function rolloverbgemerald(elmnt) {
	document.getElementById('div2').src = img3.src
}

// Returns "elmnt" to normal
function clearbgemerald(elmnt) {
	document.getElementById('div2').src = img4.src
}

// Highlights "elmnt" in black
function rolloverbgcopper(elmnt) {
	document.getElementById('div3').src = img5.src
}

// Returns "elmnt" to normal
function clearbgcopper(elmnt) {
	document.getElementById('div3').src = img6.src
}

// Highlights "elmnt" in black
function rolloverbgblood(elmnt) {
	document.getElementById('div4').src = img7.src
}

// Returns "elmnt" to normal
function clearbgblood(elmnt) {
	document.getElementById('div4').src = img8.src
}

// Highlights "elmnt" in black
function rolloverbggrey(elmnt) {
	document.getElementById('div5').src = img9.src
}

// Returns "elmnt" to normal
function clearbggrey(elmnt) {
	document.getElementById('div5').src = img10.src

}




