/* groesse */
function rate_groesse(rating,rid) {
    try {
		req = window.XMLHttpRequest?new XMLHttpRequest():
        new ActiveXObject("Microsoft.XMLHTTP");
    } catch (e) {
    //Kein AJAX Support
    }
	req.onreadystatechange = handlegroesse;
	req.open('get', '/ajax_hunderassen.html?mode=update1&rating='+rating+'&rid='+rid);
	rating = rating * 21;
	document.getElementById('current-rating1').style.width = rating+'px';
	req.send(null);
	req.rid = rid;
}

function handlegroesse() {
	if ((req.readyState == 4) && (req.status == 200)) {
		rid = req.rid;
		reloadgroesse(rid);
    }
}

function reloadgroesse(rid) {
    try {
		req1 = window.XMLHttpRequest?new XMLHttpRequest():
        new ActiveXObject("Microsoft.XMLHTTP");
    } catch (e) {
    //Kein AJAX Support
    }
    req1.onreadystatechange = handlerelaodgroesse;
	req1.open('get', '/ajax_hunderassen.html?mode=reload1&rid='+rid);
	req1.send(null);
	req.rid = rid;
}

function handlerelaodgroesse(rid) {
	if ((req1.readyState == 4) && (req1.status == 200)) {
		document.getElementById('rating1').innerHTML = req1.responseText;
	}
}

/* Futter */
function rate_futter(rating,rid) {
    try {
		req = window.XMLHttpRequest?new XMLHttpRequest():
        new ActiveXObject("Microsoft.XMLHTTP");
    } catch (e) {
    //Kein AJAX Support
    }
	req.onreadystatechange = handlefutter;
	req.open('get', '/ajax_hunderassen.html?mode=update2&rating='+rating+'&rid='+rid);
	rating = rating * 21;
	document.getElementById('current-rating2').style.width = rating+'px';
	req.send(null);
	req.rid = rid;
}

function handlefutter() {
	if ((req.readyState == 4) && (req.status == 200)) {
		rid = req.rid;
		reloadfutter(rid);
    }
}

function reloadfutter(rid) {
    try {
		req1 = window.XMLHttpRequest?new XMLHttpRequest():
        new ActiveXObject("Microsoft.XMLHTTP");
    } catch (e) {
    //Kein AJAX Support
    }
    req1.onreadystatechange = handlerelaodfutter;
	req1.open('get', '/ajax_hunderassen.html?mode=reload2&rid='+rid);
	req1.send(null);
	req.rid = rid;
}

function handlerelaodfutter(rid) {
	if ((req1.readyState == 4) && (req1.status == 200)) {
		document.getElementById('rating2').innerHTML = req1.responseText;
	}
}

/* Fellpflege */
function rate_fellpflege(rating,rid) {
    try {
		req = window.XMLHttpRequest?new XMLHttpRequest():
        new ActiveXObject("Microsoft.XMLHTTP");
    } catch (e) {
    //Kein AJAX Support
    }
	req.onreadystatechange = handlefellpflege;
	req.open('get', '/ajax_hunderassen.html?mode=update3&rating='+rating+'&rid='+rid);
	rating = rating * 21;
	document.getElementById('current-rating3').style.width = rating+'px';
	req.send(null);
	req.rid = rid;
}

function handlefellpflege() {
	if ((req.readyState == 4) && (req.status == 200)) {
		rid = req.rid;
		reloadfellpflege(rid);
    }
}

function reloadfellpflege(rid) {
    try {
		req1 = window.XMLHttpRequest?new XMLHttpRequest():
        new ActiveXObject("Microsoft.XMLHTTP");
    } catch (e) {
    //Kein AJAX Support
    }
    req1.onreadystatechange = handlerelaodfellpflege;
	req1.open('get', '/ajax_hunderassen.html?mode=reload3&rid='+rid);
	req1.send(null);
	req.rid = rid;
}

function handlerelaodfellpflege(rid) {
	if ((req1.readyState == 4) && (req1.status == 200)) {
		document.getElementById('rating3').innerHTML = req1.responseText;
	}
}

/* Aktivität */
function rate_aktivitaet(rating,rid) {
    try {
		req = window.XMLHttpRequest?new XMLHttpRequest():
        new ActiveXObject("Microsoft.XMLHTTP");
    } catch (e) {
    //Kein AJAX Support
    }
	req.onreadystatechange = handleaktivitaet;
	req.open('get', '/ajax_hunderassen.html?mode=update4&rating='+rating+'&rid='+rid);
	rating = rating * 21;
	document.getElementById('current-rating4').style.width = rating+'px';
	req.send(null);
	req.rid = rid;
}

function handleaktivitaet() {
	if ((req.readyState == 4) && (req.status == 200)) {
		rid = req.rid;
		reloadaktivitaet(rid);
    }
}

function reloadaktivitaet(rid) {
    try {
		req1 = window.XMLHttpRequest?new XMLHttpRequest():
        new ActiveXObject("Microsoft.XMLHTTP");
    } catch (e) {
    //Kein AJAX Support
    }
    req1.onreadystatechange = handlerelaodaktivitaet;
	req1.open('get', '/ajax_hunderassen.html?mode=reload4&rid='+rid);
	req1.send(null);
	req.rid = rid;
}

function handlerelaodaktivitaet(rid) {
	if ((req1.readyState == 4) && (req1.status == 200)) {
		document.getElementById('rating4').innerHTML = req1.responseText;
	}
}

/* Aktivität */
function rate_freundlichkeit(rating,rid) {
    try {
		req = window.XMLHttpRequest?new XMLHttpRequest():
        new ActiveXObject("Microsoft.XMLHTTP");
    } catch (e) {
    //Kein AJAX Support
    }
	req.onreadystatechange = handlefreundlichkeit;
	req.open('get', '/ajax_hunderassen.html?mode=update5&rating='+rating+'&rid='+rid);
	rating = rating * 21;
	document.getElementById('current-rating5').style.width = rating+'px';
	req.send(null);
	req.rid = rid;
}

function handlefreundlichkeit() {
	if ((req.readyState == 4) && (req.status == 200)) {
		rid = req.rid;
		reloadfreundlichkeit(rid);
    }
}

function reloadfreundlichkeit(rid) {
    try {
		req1 = window.XMLHttpRequest?new XMLHttpRequest():
        new ActiveXObject("Microsoft.XMLHTTP");
    } catch (e) {
    //Kein AJAX Support
    }
    req1.onreadystatechange = handlerelaodfreundlichkeit;
	req1.open('get', '/ajax_hunderassen.html?mode=reload5&rid='+rid);
	req1.send(null);
	req.rid = rid;
}

function handlerelaodfreundlichkeit(rid) {
	if ((req1.readyState == 4) && (req1.status == 200)) {
		document.getElementById('rating5').innerHTML = req1.responseText;
	}
}

/* Wachhund */
function rate_wachhund(rating,rid) {
    try {
		req = window.XMLHttpRequest?new XMLHttpRequest():
        new ActiveXObject("Microsoft.XMLHTTP");
    } catch (e) {
    //Kein AJAX Support
    }
	req.onreadystatechange = handlewachhund;
	req.open('get', '/ajax_hunderassen.html?mode=update6&rating='+rating+'&rid='+rid);
	rating = rating * 21;
	document.getElementById('current-rating6').style.width = rating+'px';
	req.send(null);
	req.rid = rid;
}

function handlewachhund() {
	if ((req.readyState == 4) && (req.status == 200)) {
		rid = req.rid;
		reloadwachhund(rid);
    }
}

function reloadwachhund(rid) {
    try {
		req1 = window.XMLHttpRequest?new XMLHttpRequest():
        new ActiveXObject("Microsoft.XMLHTTP");
    } catch (e) {
    //Kein AJAX Support
    }
    req1.onreadystatechange = handlerelaodwachhund;
	req1.open('get', '/ajax_hunderassen.html?mode=reload6&rid='+rid);
	req1.send(null);
	req.rid = rid;
}

function handlerelaodwachhund(rid) {
	if ((req1.readyState == 4) && (req1.status == 200)) {
		document.getElementById('rating6').innerHTML = req1.responseText;
	}
}

/* Dressur */
function rate_dressur(rating,rid) {
    try {
		req = window.XMLHttpRequest?new XMLHttpRequest():
        new ActiveXObject("Microsoft.XMLHTTP");
    } catch (e) {
    //Kein AJAX Support
    }
	req.onreadystatechange = handledressur;
	req.open('get', '/ajax_hunderassen.html?mode=update7&rating='+rating+'&rid='+rid);
	rating = rating * 21;
	document.getElementById('current-rating7').style.width = rating+'px';
	req.send(null);
	req.rid = rid;
}

function handledressur() {
	if ((req.readyState == 4) && (req.status == 200)) {
		rid = req.rid;
		reloaddressur(rid);
    }
}

function reloaddressur(rid) {
    try {
		req1 = window.XMLHttpRequest?new XMLHttpRequest():
        new ActiveXObject("Microsoft.XMLHTTP");
    } catch (e) {
    //Kein AJAX Support
    }
    req1.onreadystatechange = handlerelaoddressur;
	req1.open('get', '/ajax_hunderassen.html?mode=reload7&rid='+rid);
	req1.send(null);
	req.rid = rid;
}

function handlerelaoddressur(rid) {
	if ((req1.readyState == 4) && (req1.status == 200)) {
		document.getElementById('rating7').innerHTML = req1.responseText;
	}
}
