var W3CDOM = (document.createElement && document.getElementsByTagName);
var nav = new Array();
var as = new Array();
window.onload = init;


function init()
{
	       if (!W3CDOM) return;
         doit();

}

function doit(){
    var ref =   document.getElementById('reference');
    var as =    ref.getElementsByTagName('a');
    for(foo = 0; foo < as.length; foo++){	
    if(	as[foo].id ){
    as[foo].number  = as[foo].id;
    as[foo].onmouseover = test;
    }
    }		
}
function test(){

    var find = document.getElementById('right');
    var finda = find.getElementsByTagName('a');
    for(x = 0; x < finda.length; x++){	
    finda[x].style.color = '#0B3D91';
    }


    var stringfrom = this.number;  
    var splits = new Array();
    var ids = new Array();
    
    splits = stringfrom.split('_');

    var refids =   document.getElementById('right');
    var refidslis =    refids.getElementsByTagName('li');
    

    for(foo = 0; foo < refidslis.length; foo++){	
    if(refidslis[foo].id){
    if(splits[foo+1] == 0){
    var findhim = document.getElementById(refidslis[foo].id);
    var findhima = findhim.getElementsByTagName('a');
    for(x = 0; x < findhima.length; x++){	
    findhima[x].style.color = '#A3A9C5';
    }
    
    }  
    }
    }		
   return false; 
}

