var xmlhttp;

function clearText(id)
{
	document.getElementById(id).value = '';
}

function sendMail(afsender,modtager,id,path)
{
	createObject();
		
	var url = path+'1mail.php?afsender='+afsender+'&modtager='+modtager+'&id='+id;
	xmlhttp.open("GET",url,false);
	xmlhttp.send(null);
	document.getElementById('tipArea').innerHTML = xmlhttp.responseText;
}

function createObject()
{
	if (window.XMLHttpRequest)
	{
		xmlhttp=new XMLHttpRequest();
	}
	else
	{
		xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
	}
	
	return xmlhttp;
}

function showTip()
{
	document.getElementById('tipArea').style.display = 'inline-block';
}