var r_address = null;
var s_address = null;
function doVote(type, textId, ip)
{
	gtype = type;
	gtextId = textId;
	r_address = ip + 1;
	//alert(type+guestId);
	var params = "action=vote&type="+type+"&text_id="+textId;
	$.ajax({
	type: "get",
	url: "index.cfm",
	data: params,
	});
	if(gtype == "an")
	{
	var id = gtextId;
	$('span#s-'+id).empty();
	$('span#s-'+id).append('<img src="images/+.png" border="0" />('+ip+')');
}
	else if(gtype = "as")
	{
	var id = gtextId;
	$('<span><img src="images/-.png" /> ('+ip+')</span>').insertBefore('span#c-'+id);
	$('span#m-'+id).remove();
}
}

