function show_hide_frm(id) 
{
	var d = document.getElementById(id);
	for (var i = 1; i<=3; i++) 
	{
		
		if (document.getElementById('frm'+i)) 
		{
			//alert(i);
			document.getElementById('frm'+i).style.display='none';
		}
	}
	if (d) {d.style.display='block';}
}



/*
function addLoadEvent(func) 
{
   var oldonload = window.onload;
   if (typeof window.onload != 'function') {
       window.onload = func;
   } else {
       window.onload = function() {
           if (oldonload) {
               oldonload();
           }
           func();
       }
   }
}
*/

function changeNamedTab(tabFamily,nr,max)
{
	
	for (var i=0; i<max; i++)
	{
		
		
		var tabName = String(tabFamily)+String(i);
		var tab = document.getElementById(tabName);
		var tabHead=document.getElementById(tabName+'head');				

		if(i==nr)
		{
			tab.style.display='block';
			if(tabHead)
			{
				tabHead.style.fontWeight='bold';
				if(tabFamily=='eventTab')
				{
					tabHead.style.background='#ffc url(../design_img/smallTabs2TabHover.jpg) top left repeat-x';
				}
				else
				{
					tabHead.style.background='#ffc url(../design_img/smallTabsTabHover.jpg) top left repeat-x';
				}
				
			}
		}
		else
		{
			tab.style.display='none';
			if(tabHead)
			{
				tabHead.style.fontWeight='normal';
				if(tabFamily=='eventTab')
				{
					tabHead.style.background='#ffc url(../design_img/smallTabs2TabBg.jpg) top left repeat-x';
				}
				else
				{
					tabHead.style.background='#ffc url(../design_img/smallTabsTabBg.jpg) top left repeat-x';
				}
			}
		}
		
		
	}
	
}


function smalltabMouseOut(tabFamily,obj)
{
	if(obj.style.fontWeight=='normal')
	{
		if(tabFamily=='eventTab')
		{
			obj.style.background='#ffc url(../design_img/smallTabs2TabBg.jpg) top left repeat-x';
		}
		else
		{
			obj.style.background='#ffc url(../design_img/smallTabsTabBg.jpg) top left repeat-x';
		}
		
	}
	
}
