<!--

/**
  * General Function
  * @Function Name	: toggleLeftNav
  * Element			: Image 
  * Event 			: onclick 
  * @Functionality	: Expand or Collapse left Navigation tree
  *					  
  * @Author(s)		: Rana
  * 
  */
function toggleLeftNav(mainMenuNo)
{
	// If Requested Menu opened - Close the All menu except requested menu
	// Else - Close all Menu
	
	// Define No of Main Menus	
	var mainMenu = 4;

	// Main Menu Div tag id starts with divIdMm
	// Main Menu Button id starts with btnIdMm
	inDiv = document.getElementById('divIdMm' + mainMenuNo);
	inBttn = document.getElementById('btnIdMm' + mainMenuNo);

	// Expand or Collapse main Menu
	for(i=1; i<=mainMenu;i++)
	{
		if(i != mainMenuNo)
		{
			document.getElementById('divIdMm'+i).style.display='none';
			document.getElementById('btnIdMm'+i).src = '/caasWeb/opencms/caas/en/images/boxleftnavplus.gif';
		}
		else
		{
			if (inDiv.style.display=='none')
			{
				inDiv.style.display='block';
				inBttn.src = '/caasWeb/opencms/caas/en/images/boxleftnavminus.gif';
			}
			else 
			{
				inDiv.style.display='none';
				inBttn.src = '/caasWeb/opencms/caas/en/images/boxleftnavplus.gif';
			}
		}
	}
	// Call the function to chnage the icon for all Removed menus
	removedMenusItem();
	
}

/**
  * General Function
  * @Function Name	: toggleLeftNav
  * Element			: Image 
  * Event 			: onclick 
  * @Functionality	: Expand or Collapse left Navigation tree
  *					  
  * @Author(s)		: Rana
  * 
  */
function toggleLeftSubMenu(mainMenuNo,subMenuNo)
{
	// If Requested Menu opened - Close the All menu except requested menu
	// Else - Close all Menu
	

	// Define No of Sub Menus	
	var subMenu = 11;
	// Main Menu Div tag id starts with divIdMm
	// Main Menu Button id starts with btnIdMm
	inDiv = document.getElementById('divIdMm' + mainMenuNo);
	inBttn = document.getElementById('btnIdMm' + mainMenuNo);

	// Sub Menu Div tag id starts with divIdSm
	// Sub Menu Button id starts with btnIdSm
	if(subMenuNo !="")
	{
		subDiv = document.getElementById('divIdSm' + subMenuNo);
		subBttn = document.getElementById('btnIdSm' + subMenuNo);
	}
	
	

	// Expand or Collapse Sub Menu
	if(subMenuNo !="")
	{
		for(i=1; i<=subMenu;i++)
		{
			if(i != subMenuNo)
			{
				document.getElementById('divIdSm'+i).style.display='none';
				document.getElementById('btnIdSm'+i).src = '/caasWeb/opencms/caas/en/images/boxleftnavplussmall.gif';
			}
			else
			{
				if (subDiv.style.display=='none')
				{
					subDiv.style.display='block';
					subBttn.src = '/caasWeb/opencms/caas/en/images/boxleftnavminussmall.gif';
				}
				else 
				{
					subDiv.style.display='none';
					subBttn.src = '/caasWeb/opencms/caas/en/images/boxleftnavplussmall.gif';
				}
			}
		}
	}

	// Call the function to chnage the icon for all Removed menus
	removedMenusItem();
}

/**
  * General Function
  * @Function Name	: removedMenusItem
  * @Functionality	: Change the unused menu items icon
  *					
  *					  
  * @Author(s)		: Rana
  * 
  */
function removedMenusItem()
{
	var removeMenuItems = new Array;
	// Add the Button id of the removed menu item
	removeMenuItems[0] = "btnIdSm5"		// 1.divIdSm5 - Publicity Meterials	sm no -5	// This Sub Menu not in Use
	
	for(i=0;i<removeMenuItems.length;i++)
		document.getElementById(removeMenuItems[i]).src = '/caasWeb/opencms/caas/en/images/boxleftnavdotsmall.gif';
}

// Main & Sub Menu Details
/*

Total No of Main Menus[divIdMm] = 4

1. divIdMm1	-	General 				mm no -1

	Sub Menu for About Us divIdMm1
	Total No of Sub Menusfor About Us = 1

	1.divIdSm1 - Profile				sm no-1

2. divIdMm2	-	Our Services			mm no -2

	Total No of Sub Menus for Our Services = 3
	1.divIdSm2 - Water					sm no -2 
	2.divIdSm3 - Used Water				sm no -3
	3.divIdSm4 - Drainage				sm no -4 

3. divIdMm3	-	Conservation			mm no -3

	Total No of Sub Menus for Conservation = 2
	1.divIdSm5 - Publicity Meterials	sm no -5	// This Sub Menu not in Use
	2.divIdSm6 - Conservation Measures	sm no -6

4. divIdMm4	-	Info Center				mm no -4

	Total No of Sub Menus for Info Center = 3
	1.divIdSm7 - News Room				sm no -7 
	2.divIdSm8 - Facts & Figures		sm no -8
	3.divIdSm9 - Education				sm no -9 
	
5. divIdMm5 -	Career					mm no -5
6. divIdMm6	-	Downloads				mm no -6
	
	Total No of Sub Menus for Conservation = 2
	1.divIdSm10 - Forms					sm no -10 
	2.divIdSm11 - Standard Spec			sm no -11


*/

/**
  *
  * @Function Name	: openNewWindow
  * Event 			: onclick 
  * @Functionality	: To Open a new window
  *					  
  * @Author(s)		: Rana
  * 
  */

function openNewWindow(url,title,features)
{
	win = window.open(url,title,features);
	win.focus();
}



function toggleLeftNavAD(mainMenuNo)
{
	// If Requested Menu opened - Close the All menu except requested menu
	// Else - Close all Menu
	
	// Define No of Main Menus	
	var mainMenu = 3;

	// Main Menu Div tag id starts with divIdMm
	// Main Menu Button id starts with btnIdMm
	inDiv = document.getElementById('divIdMm' + mainMenuNo);
	inBttn = document.getElementById('btnIdMm' + mainMenuNo);

	// Expand or Collapse main Menu
	for(i=1; i<=mainMenu;i++)
	{
		if(i != mainMenuNo)
		{
			document.getElementById('divIdMm'+i).style.display='none';
			document.getElementById('btnIdMm'+i).src = '/caasWeb/opencms/caas/en/images/boxleftnavplus.gif';
		}
		else
		{
			if (inDiv.style.display=='none')
			{
				inDiv.style.display='block';
				inBttn.src = '/caasWeb/opencms/caas/en/images/boxleftnavminus.gif';
			}
			else 
			{
				inDiv.style.display='none';
				inBttn.src = '/caasWeb/opencms/caas/en/images/boxleftnavplus.gif';
			}
		}
	}
	// Call the function to chnage the icon for all Removed menus
	
	
}