$(document).ready(function() {


    $("#content").mouseout(function() {
        $.each($("#spalte_rechts").find("a"), function(i,obj) {
                $("#"+obj.id).removeClass('highlight');
           });
    });
   
   $.each($("#spalte_rechts").find("a"), function(i,obj) {
        var pferd=obj.id.substring(2,obj.id.length);
        
           $("#"+obj.id).hover(
               function() { 
                   console.log("pferd ist::"+ pferd);
                   $("#img_"+pferd).addClass("img_highlight");
               },
               function() {
                   $("#img_"+pferd).removeClass("img_highlight");
               }
           );
               
    });

});

function highlight(pferd){
    
    
    
   // console.log("hier::"+ $("#a_"+pferd).css('color'));
    //$("#spalte_rechts").children("a").
    $.each($("#spalte_rechts").find("a"), function(i,obj) {
   	    
   	    
		//	obj.removeClass('highlight');
    
        $("#"+obj.id).removeClass('highlight');
    
  
        
	});
    //$("#a_"+pferd).css({ color: "#f45b25" });
    $("#a_"+pferd).addClass("highlight");
}

function highlight_img(pferd){
    
    
    
   // console.log("hier::"+ $("#a_"+pferd).css('color'));
    //$("#spalte_rechts").children("a").
    $.each($("#spalte_rechts").find("a"), function(i,obj) {
   	    
   	    console.log("i::"+ obj.id);
		//	obj.removeClass('highlight');
    
        $("#"+obj.id).removeClass('highlight');
    
  
        
	});
    //$("#a_"+pferd).css({ color: "#f45b25" });
    $("#a_"+pferd).addClass("highlight");
}


