function selTab(sel,ind, maxlength){ 
          for(i=1;i<maxlength+1;i++){ 
               document.getElementById('tab'+i).className = 'up'; 
               document.getElementById('page'+i).className = 'hide'; 
          } 
          document.getElementById('tab'+ind).className = 'act'; 
          document.getElementById('page'+ind).className = 'show'; 
}

function selTabMultiple(sel,ind, maxlength, tabName, pageName){ 
          for(i=1;i<maxlength+1;i++){ 
               document.getElementById(tabName+i).className = 'up'; 
               document.getElementById(pageName+i).className = 'hide'; 
          } 
          document.getElementById(tabName+ind).className = 'act'; 
          document.getElementById(pageName+ind).className = 'show'; 
}




function selTab_2(sel,ind, maxlength){ 
          for(i=1;i<maxlength+1;i++){ 
                document.getElementById('box'+i).className = 'hide'; 
          } 
          document.getElementById('box'+ind).className = 'show'; 
}

function selTab_2Multiple(sel,ind, maxlength, tabName, boxName){ 
          for(i=1;i<maxlength+1;i++){ 
               document.getElementById(tabName+i).className = 'up'; 
               document.getElementById(boxName+i).className = 'hide'; 
          } 
          document.getElementById(tabName+ind).className = 'act'; 
          document.getElementById(boxName+ind).className = 'show'; 
}
