/*#############################################################################

FILE:	showDiv.js

	Copyright © 2005 Navitaire Inc. All rights reserved.

	This source code is (i) proprietary to and a trade secret of Navitaire Inc.
	and (ii) protected by copyright law and international treaties.
	Unauthorized disclosure, reproduction, distribution or alteration of this
	source code, or any portion of it, may result in severe civil and criminal
	penalties and will be prosecuted to the maximum extent possible under
	the law.

	www.navitaire.com

DESCRIPTION:

	Contains javascript to show or hid an html div tag by id

#############################################################################*/

	var ns4 = (document.layers) ? true:false;
	var ie4 = (document.all && !document.getElementById) ? true:false;
	var ie5 = (document.all && document.getElementById)  ? true:false;
	var ns6 = (!document.all && document.getElementById) ? true:false;

/*  //This can be uncommented when testing in new browsers.
	alert ("Browser Compatability:" +
			"\nns4:" + ns4 +
			"\nie4:" + ie4 +
			"\nie5:" + ie5 +
			"\nns6:" + ns6);
*/
	
/*###############################
#
# Function: showDiv()
#
# Parameter: 	'show' 		- either true or false
#		'id'		- the div section
#
# Description: Shows or hides div sections in html page
#
#
#################################*/		
	
	function showDiv(show, id)
	{
		if (show)
		{
				if (ie4) document.all[id].style.display	= 'block';
				else if (ns4) document.layers[id].display 	= 'block';
				else if (ns6 || ie5) document.getElementById(id).style.display	= 'block';
		}
		else
		{
				if (ie4) document.all[id].style.display = 'none';
				else if (ns4) document.layers[id].display = 'none';
				else if (ns6 || ie5) document.getElementById(id).style.display= 'none';
		}
	}