﻿try
{
	

	
	// If the home page is not displaying
	if (!IsHomePage)
	{
	
		// Get references to left sidebar and sub navigation space
		LeftSidebar = document.getElementById("left_sidebar")
		SubNav = document.getElementById("sub_nav")
			
		// If there is no sub navigation, change the style of the left sidebar so no background image appears		
		if (SubNav.getElementsByTagName("a").length == 0)
		{
			LeftSidebar.style.backgroundImage = "url(/images/transparent.gif)"
		}
						
	}
					
}

catch(e)
{}


/* 
-------------------------------------------------------------------
Switch to 2 column layout
-------------------------------------------------------------------
*/
function TwoColumn()
{

	if (!IsHomePage)
	{
		document.getElementById("full_column").style.width = "640px"
		document.getElementById("right_sidebar").style.display = "none"
	}

}



/* 
-------------------------------------------------------------------
Submit main form
-------------------------------------------------------------------
*/

function SubmitMasterForm(FormAction,FormTarget)

{

	// Get reference to main form
	f = document.forms[0]

	// Set action of form
	if (FormAction != "" && FormAction != null)
	{f.action = FormAction}

	// Set target of form if necessary
	if (FormTarget != "" && FormTarget != null)
	{f.target = FormTarget}

	f.submit()

}