
function switchBox(n){
	var len=9;
	for(i=0;i<len;i++){
		document.getElementById("SWBox_"+i).style.display=(i==n)?"block":"none";
		document.getElementById("level2_tab"+i).style.color=(i==n)?"#FF9933":"#666666";
		document.getElementById("BTN_"+i).style.backgroundColor=(i==n)?"#FFFFFF":"transparent";
		document.getElementById("BTN_"+i).style.color=(i==n)?"#FF9933":"#666666";
		document.getElementById("BTN_"+i).style.fontWeight=(i==n)?"bold":"normal";
	}
}

function changeTab(n){
 
	var len=3;
	for(i=1;i<=len;i++){
		document.getElementById("tabox_"+i).style.display=(i==n)?"block":"none";
		document.getElementById("levelA_tab"+i).style.color=(i==n)?"#ffffff":"#666666";
		document.getElementById("tab_head_"+i).style.background=(i==n)?"url(../images/lab_bg2.gif)":"none";
		document.getElementById("tab_head_"+i).style.color=(i==n)?"#ffffff":"#666666";
		document.getElementById("tab_head_"+i).style.fontWeight=(i==n)?"bold":"normal";
	}
}

function Tab_a(n){
    
	var len=3;
	for(i=1;i<=len;i++){
		document.getElementById("tabox_a_"+i).style.display=(i==n)?"block":"none";
		document.getElementById("levelB_tab"+i).style.color=(i==n)?"#ffffff":"#666666";
		document.getElementById("tab_head_a_"+i).style.background=(i==n)?"url(images/lab_down.gif)":"url(images/lab_up.gif)";
		document.getElementById("tab_head_a_"+i).style.color=(i==n)?"#ffffff":"#666666";
		document.getElementById("tab_head_a_"+i).style.fontWeight=(i==n)?"bold":"normal";
	}
}

function Tab_b(n){
    
	var len=3;
	for(i=1;i<=len;i++){
		document.getElementById("tabox_b_"+i).style.display=(i==n)?"block":"none";
		document.getElementById("levelC_tab"+i).style.color=(i==n)?"#ffffff":"#666666";
		document.getElementById("tab_head_b_"+i).style.background=(i==n)?"url(images/lab_down.gif)":"url(images/lab_up.gif)";
		document.getElementById("tab_head_b_"+i).style.color=(i==n)?"#ffffff":"#666666";
		document.getElementById("tab_head_b_"+i).style.fontWeight=(i==n)?"bold":"normal";
	}
}

function Tab_c(n){
    
	var len=3;
	for(i=1;i<=len;i++){
		document.getElementById("tabox_c_"+i).style.display=(i==n)?"block":"none";
		document.getElementById("levelD_tab"+i).style.color=(i==n)?"#ffffff":"#666666";
		document.getElementById("tab_head_c_"+i).style.background=(i==n)?"url(images/lab_down.gif)":"url(images/lab_up.gif)";
		document.getElementById("tab_head_c_"+i).style.color=(i==n)?"#ffffff":"#666666";
		document.getElementById("tab_head_c_"+i).style.fontWeight=(i==n)?"bold":"normal";
	}
}
function Tab_d(n){
    
	var len=3;
	for(i=1;i<=len;i++){
		document.getElementById("tabox_d_"+i).style.display=(i==n)?"block":"none";
		document.getElementById("levelE_tab"+i).style.color=(i==n)?"#ffffff":"#666666";
		document.getElementById("tab_head_d_"+i).style.background=(i==n)?"url(images/lab_down.gif)":"url(images/lab_up.gif)";
		document.getElementById("tab_head_d_"+i).style.color=(i==n)?"#ffffff":"#666666";
		document.getElementById("tab_head_d_"+i).style.fontWeight=(i==n)?"bold":"normal";
	}
}
function Tab_e(n){
    
	var len=3;
	for(i=1;i<=len;i++){
		document.getElementById("tabox_e_"+i).style.display=(i==n)?"block":"none";
		document.getElementById("levelF_tab"+i).style.color=(i==n)?"#ffffff":"#666666";
		document.getElementById("tab_head_e_"+i).style.background=(i==n)?"url(images/lab_down.gif)":"url(images/lab_up.gif)";
		document.getElementById("tab_head_e_"+i).style.color=(i==n)?"#ffffff":"#666666";
		document.getElementById("tab_head_e_"+i).style.fontWeight=(i==n)?"bold":"normal";
	}
}
function Tab_f(n){
    
	var len=3;
	for(i=1;i<=len;i++){
		document.getElementById("tabox_f_"+i).style.display=(i==n)?"block":"none";
		document.getElementById("levelG_tab"+i).style.color=(i==n)?"#ffffff":"#666666";
		document.getElementById("tab_head_f_"+i).style.background=(i==n)?"url(images/lab_down.gif)":"url(images/lab_up.gif)";
		document.getElementById("tab_head_f_"+i).style.color=(i==n)?"#ffffff":"#666666";
		document.getElementById("tab_head_f_"+i).style.fontWeight=(i==n)?"bold":"normal";
	}
}
function Tab_g(n){
    
	var len=3;
	for(i=1;i<=len;i++){
		document.getElementById("tabox_g_"+i).style.display=(i==n)?"block":"none";
		document.getElementById("levelH_tab"+i).style.color=(i==n)?"#ffffff":"#666666";
		document.getElementById("tab_head_g_"+i).style.background=(i==n)?"url(images/lab_down.gif)":"url(images/lab_up.gif)";
		document.getElementById("tab_head_g_"+i).style.color=(i==n)?"#ffffff":"#666666";
		document.getElementById("tab_head_g_"+i).style.fontWeight=(i==n)?"bold":"normal";
	}
}
function Tab_h(n){
    
	var len=3;
	for(i=1;i<=len;i++){
		document.getElementById("tabox_h_"+i).style.display=(i==n)?"block":"none";
		document.getElementById("levelI_tab"+i).style.color=(i==n)?"#ffffff":"#666666";
		document.getElementById("tab_head_h_"+i).style.background=(i==n)?"url(images/lab_down.gif)":"url(images/lab_up.gif)";
		document.getElementById("tab_head_h_"+i).style.color=(i==n)?"#ffffff":"#666666";
		document.getElementById("tab_head_h_"+i).style.fontWeight=(i==n)?"bold":"normal";
	}
}
function Tab_i(n){
    
	var len=3;
	for(i=1;i<=len;i++){
		document.getElementById("tabox_i_"+i).style.display=(i==n)?"block":"none";
		document.getElementById("levelJ_tab"+i).style.color=(i==n)?"#ffffff":"#666666";
		document.getElementById("tab_head_i_"+i).style.background=(i==n)?"url(images/lab_down.gif)":"url(images/lab_up.gif)";
		document.getElementById("tab_head_i_"+i).style.color=(i==n)?"#ffffff":"#666666";
		document.getElementById("tab_head_i_"+i).style.fontWeight=(i==n)?"bold":"normal";
	}
}
function Tab_j(n){
    
	var len=3;
	for(i=1;i<=len;i++){
		document.getElementById("tabox_j_"+i).style.display=(i==n)?"block":"none";
		document.getElementById("levelK_tab"+i).style.color=(i==n)?"#ffffff":"#666666";
		document.getElementById("tab_head_j_"+i).style.background=(i==n)?"url(images/lab_down.gif)":"url(images/lab_up.gif)";
		document.getElementById("tab_head_j_"+i).style.color=(i==n)?"#ffffff":"#666666";
		document.getElementById("tab_head_j_"+i).style.fontWeight=(i==n)?"bold":"normal";
	}
}

function onInit(tab){
	switchBox(tab);
	
	for(i=1;i<4;i++){
		document.getElementById("tabox_"+i).style.display="none";
		}
	//document.getElementById("tabox_"+tab).style.display="block";
	changeTab(tab);
	Tab_a(1);
	Tab_b(1);
	Tab_c(1);
	Tab_d(1);
	Tab_e(1);
	Tab_f(1);
	Tab_g(1);
	Tab_h(1);
	Tab_i(1);
	Tab_j(1);
}

