function Validate()
{
	var Msg="";

	if (document.getElementById("toemail1").value.length == 0)
	{ Msg=Msg + "* The Recipient's Email Address\n"; }

	if (document.getElementById("toemail1").value != document.getElementById("toemail2").value)
	{ Msg=Msg + "* The Recipient's Email Address Does Not Match\n"; }

	if (Msg == "")
	{
		if (document.getElementById("toemail1").value.indexOf("@") == -1)
		{ Msg=Msg + "* The Recipient's Email Address\n"; }

		else if (document.getElementById("toemail1").value.indexOf(".") == -1)
		{ Msg=Msg + "* The Recipient's Email Address\n"; }
	}

	if (document.getElementById("from").value.length == 0)
	{ Msg=Msg + "* The From Field\n"; }

	if (document.getElementById("fromemail").value.length == 0)
	{ Msg=Msg + "* The Sender's Email Address\n"; }

	if (Msg == "")
	{
		if (document.getElementById("fromemail").value.indexOf("@") == -1)
		{ Msg=Msg + "* The Sender's Email Address\n"; }

		else if (document.getElementById("fromemail").value.indexOf(".") == -1)
		{ Msg=Msg + "* The Sender's Email Address\n"; }
	}

	if (Msg != "")
	{ alert('Sorry, but before proceeding, you\nmust fill-in the following field(s):\n\n' + Msg); }

	else
     { return true; }

	return false;
}

document.getElementById("giftcertfrm").onsubmit=Validate;