var panels = new Array('panel1', 'panel2', 'panel3');
function showPanel(tab, panelName)
{
	var panelToShow = document.getElementById(panelName);
	for(i = 0; i< panels.length; i++)
	{
		// Get the current panel
		var curPanel = document.getElementById(panels[i]);
		// If it exists, hide it
		if (curPanel != null)
			curPanel.style.display = 'none';
	}
	// This line works around a display bug in Gecko-based browsers
	panelToShow.style.display = 'inline';
	// Show the panel
	panelToShow.style.display = 'block';
	return false;
}

var panels2 = new Array('panel4', 'panel5', 'panel6');
function showPanel2(tab2, panel2Name)
{
	var panel2ToShow = document.getElementById(panel2Name);
	for(i = 0; i< panels2.length; i++)
	{
		// Get the current panel
		var curPanel2 = document.getElementById(panels2[i]);
		// If it exists, hide it
		if (curPanel2 != null)
			curPanel2.style.display = 'none';
	}
	// This line works around a display bug in Gecko-based browsers
	panel2ToShow.style.display = 'inline';
	// Show the panel
	panel2ToShow.style.display = 'block';
	return false;
}

var panels3 = new Array('panel7', 'panel8');
function showPanel3(tab3, panel3Name)
{
	var panel3ToShow = document.getElementById(panel3Name);
	for(i = 0; i< panels3.length; i++)
	{
		// Get the current panel
		var curPanel3 = document.getElementById(panels3[i]);
		// If it exists, hide it
		if (curPanel3 != null)
			curPanel3.style.display = 'none';
	}
	// This line works around a display bug in Gecko-based browsers
	panel3ToShow.style.display = 'inline';
	// Show the panel
	panel3ToShow.style.display = 'block';
	return false;
}

var panels4 = new Array('panel10', 'panel11');
function showPanel4(tab4, panel4Name)
{
	var panel4ToShow = document.getElementById(panel4Name);
	for(i = 0; i< panels4.length; i++)
	{
		// Get the current panel
		var curPanel4 = document.getElementById(panels4[i]);
		// If it exists, hide it
		if (curPanel4 != null)
			curPanel4.style.display = 'none';
	}
	// This line works around a display bug in Gecko-based browsers
	panel4ToShow.style.display = 'inline';
	// Show the panel
	panel4ToShow.style.display = 'block';
	return false;
}

var panels5 = new Array('panel12', 'panel13', 'panel14');
function showPanel5(tab5, panel5Name)
{
	var panel5ToShow = document.getElementById(panel5Name);
	for(i = 0; i< panels5.length; i++)
	{
		// Get the current panel
		var curPanel5 = document.getElementById(panels5[i]);
		// If it exists, hide it
		if (curPanel5 != null)
			curPanel5.style.display = 'none';
	}
	// This line works around a display bug in Gecko-based browsers
	panel5ToShow.style.display = 'inline';
	// Show the panel
	panel5ToShow.style.display = 'block';
	return false;
}

var panels6 = new Array('panel15', 'panel16');
function showPanel6(tab6, panel6Name)
{
	var panel6ToShow = document.getElementById(panel6Name);
	for(i = 0; i< panels6.length; i++)
	{
		// Get the current panel
		var curPanel6 = document.getElementById(panels6[i]);
		// If it exists, hide it
		if (curPanel6 != null)
			curPanel6.style.display = 'none';
	}
	// This line works around a display bug in Gecko-based browsers
	panel6ToShow.style.display = 'inline';
	// Show the panel
	panel6ToShow.style.display = 'block';
	return false;
}


