function toggle_div (object) {
	object = $(object);
	object.style.display = object.style.display == 'block' ? 'none' : 'block';
}
function vote (post_id, subtract) {
	new Ajax.Request(path + '/vote.php?id=' + post_id + '&subtract=' + (subtract ? '1' : '0'), {
		method: 'get',
		onSuccess: function (transport) {
			$('vote' + post_id).innerHTML = transport.headerJSON.count;
		},
		onFailure: function (transport) {
			alert('Vote failed!');
		}
	});
}