function sendtoafriend() {
var fname = document.getElementById('fname').value;
var femail = document.getElementById('femail').value;
var name = document.getElementById('yname').value;
var email = document.getElementById('yemail').value;

var url = 'common/send-to-a-friend_0.php'+fname+'&femail='+femail+'&yname='+name+'&yemail='+email;

oXml.open('GET', url, true);
oXml.onreadystatechange = processingFunctionSTAF;
oXml.send();
}

function processingFunctionSTAF() {
	if (oXml.readyState==4 || oXml.readyState=="complete") {
		document.getElementById("formcontainer").innerHTML=oXml.responseText;
		Nifty("div#formcontainer","big");
	}
}

function resetsendtoafriend() {
	document.getElementById('formcontainer').innerHTML = '<form method="GET" action="" name="form1" id="form1" onsubmit="sendtoafriend();return false;"> \
	<h3 class="blue">Please fill in the form, and click "Send Invitation" button.</h3> \
	<center class="red"><b>* Note that you may send only one invitation per day.</b></center> \
	<center class="red"><b>** Note that we DO NOT collect ot store your E-MAIL addresses while you are inviting a friend.</b></center> \
	<div>To: <input style="border:none;width:200px;" type="text" name="femail" id="femail" size="20" value="ENTER FRIEND\'S EMAIL HERE"></div> \
	<div>Dear <input style="border:none;width:200px;" type="text" name="fname" id="fname" size="20" value="ENTER FRIEND\'S NAME HERE"> <span class="red">* Please use letters and spaces only in this field.</span></div> \
	<div style="text-align:justify;">I would like to invite you to visit www.nodepositcasino.tv. This site has more than 20 no deposit offers from online casinos, where you can get up to $3000 in free casino cash. Site is updated daily and recommends safe and trusted online casinos with the highest no deposit money offers.</div> \
	<div>Warm Regards, <input style="border:none;width:200px;" type="text" name="yname" id="yname" size="20" value="ENTER YOUR NAME HERE"> <span class="red">* Please use letters and spaces only in this field.</span></div> \
	<div>Your e-mail: <input style="border:none;width:200px;" type="text" name="yemail" id="yemail" size="20" value="ENTER YOUR EMAIL HERE"></div> \
	<div style="text-align:right;"><input name="submit" type="submit" value="Send Invitation"></div> \
	</form>';

Nifty("#formcontainer","big");
}

