var VID = {
	D: function(id) {
		if (confirm('Biztos törlöd ezt a videót?')) {
			$('v_D_'+id).innerHTML = '<img src="/styles/main/images/loading.gif" />';
			eval("new Ajax.Request('/req/videos/del.req.php', {method:'post', postBody:'id='+id, onComplete: function(t) { if (t.responseText.length) alert(t.responseText); else { document.location.replace('/videok/'); } }});");
		}
	},
	DC: function(id, cid) {
		if (confirm('Biztos törlöd ezt a megjegyzést?')) {
			$('vc_D_'+cid).innerHTML = '<img src="/styles/main/images/loading.gif" />';
			eval("new Ajax.Request('/req/videos/del_comment.req.php', {method:'post', postBody:'id='+id+'&cid='+cid, onComplete: function(t) { if (t.responseText.length) alert(t.responseText); else { $('vc_cont_"+cid+"').style.display = 'none'; } }});");
		}
	},
	R: function(id, r) {
		$('v_R_'+id).innerHTML = '<br /><img src="/styles/main/images/loading.gif" />';
		eval("new Ajax.Request('/req/videos/rate.req.php', {method:'post', postBody:'id='+id+'&rating='+r, onComplete: function(t) { if (t.responseText.length) alert(t.responseText); else { $('v_R_"+id+"').innerHTML = '<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\"><tr><td>Értékelted</td><td width=\"10\">&nbsp;</td><td><img src=\"/styles/main/images/thumb_"+(r>0?'up':'down')+".png\" /></td></tr></table>'; } }});");
	}
}
