function dislike(id)
{
	//alert("rating.php?i="+id+"&r=t&t=d");
	if (window.XMLHttpRequest)
	{// code for IE7+, Firefox, Chrome, Opera, Safari
		xmlhttp = new XMLHttpRequest();
	}
	else
	{// code for IE6, IE5
		xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
	}
	
	xmlhttp.onreadystatechange=function()
	{
		if (xmlhttp.readyState==4 && xmlhttp.status==200)
		{
			box = document.getElementById("rating_box_"+id);
			box.innerHTML=xmlhttp.responseText;
			
			//box.innerHTML+="rating.php?i="+id+"&r=t&t=l";			
			//alert(xmlhttp.responseText);	
		}
	}
	xmlhttp.open("GET","rating.php?i="+id+"&r=t&t=d",true);
	xmlhttp.send();
}

function like(id)
{
	if (window.XMLHttpRequest)
	{// code for IE7+, Firefox, Chrome, Opera, Safari
		xmlhttp = new XMLHttpRequest();
	}
	else
	{// code for IE6, IE5
		xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
	}
	
	xmlhttp.onreadystatechange=function()
	{
		if (xmlhttp.readyState==4 && xmlhttp.status==200)
		{
			box = document.getElementById("rating_box_"+id);
			box.innerHTML=xmlhttp.responseText;
			
			//box.innerHTML+="rating.php?i="+id+"&r=t&t=l";			
			//alert(xmlhttp.responseText);	
		}
	}
	xmlhttp.open("GET","rating.php?i="+id+"&r=t&t=l",true);
	xmlhttp.send();
}

function toggle_show(id)
{
	//alert(id);
	var box = document.getElementById(id);
	
	if (box.style.display == "none")
	{
		box.style.display = "block";
	}
	else
	{
		box.style.display = "none"
	}
}
function show_tab(show_id, hide_id)
{
	//alert(hide_id+"_tab");
	//alert(hide_id+"_list");
	div_show = document.getElementById(show_id+"_list");
	div_show.style.display = "block";
	
	div_hide = document.getElementById(hide_id+"_list");
	div_hide.style.display = "none";
	
	tab_show = document.getElementById(show_id+"_tab");
	tab_show.className = "tab";
	
	tab_hide = document.getElementById(hide_id+"_tab");
	tab_hide.className = "hidden_tab";
}
function show_form(form_id)
{
	var form = document.getElementById(form_id);
	if(form.style.display == "none")
	{
		form.style.display = "block";
	}
	else
	{
		form.style.display = "none";
	}
}
function activate_button(field_id)
{
	var field = document.getElementById(field_id);
	var select_field = document.getElementById("select_sport");
	
	field.disabled = false;
}



