function voteonmouseover(hand,color){
	hand.src = "../pics/hand"+color+".gif";
	tooltipzeigen('vote'+color+'');
}

function voteonmouseout(hand,vote){
	hand.src = "../pics/hand"+vote+".gif";
	tooltipausblenden();
}

//Kommentar Bewertung Ajax-Anfrage
function ajaxvoteanfrage(vote,output,id){
	document.cookie = "cookietestmcp";
	if(document.cookie.indexOf("cookietestmcp") == -1){
		errordivvisible('cookiesoff','Hinweis:');	
	}
	else{
		ausgabeid = output+id;
		anfrage = ajaxXMLHttpRequest();
		if(anfrage != null){
			var url = "../func/votefunc.php?vote="+vote+"&id="+id+"";
			anfrage.open("GET", url, true);
			anfrage.onreadystatechange=ausgabe;
			anfrage.send(null);
		}
	}
}

//Kommentar Bewertung Ajax-Ausgabe
function ausgabe(){
	if(anfrage.readyState == 4){
		if(anfrage.status == 200){
			var rueckgabewert = anfrage.responseText;
			switch (rueckgabewert){
			    case "error": errordivvisible('errorajaxresponse','Fehler:');	
                break;
				case "justvote": errordivvisible('justvote','Hinweis:');
                break;
				default: document.getElementById(ausgabeid).innerHTML = rueckgabewert;
			}
		}
	}
}
