function CheckForm(Which)
    {
    if (Which.SubFirstName.value == "")
        {
        alert("You must enter your first name.");
        return false;
        }
    if (Which.SubLastName.value == "")
        {
        alert("You must enter your last name.");
        return false;
        }
    if (Which.SubAddress.value == "")
        {
        alert("You must enter your address.");
        return false;
        }
    if (Which.SubTown.value == "")
        {
        alert("You must enter your city.");
        return false;
        }
    if (Which.SubState.value == "")
        {
        alert("You must enter your state");
        return false;
        }
    if ( (Which.SubZip.value.length != 5) || isNaN(Which.SubZip.value) )
        {
        alert("You must enter a valid 5 digit zip code.");
        return false;
        }
    if (Which.SubEmail.value == "")
        {
        alert("You must enter your E-Mail Address.");
        return false;
        }
    if (Which.SubPhone.value == "")
        {
        alert("You must enter your phone number.");
        return false;
        }
    if (Which.SubAmount.value == "" || Which.SubAmount.value == "$0.00")
        {
        alert("You must enter an amount.");
        return false;
        }
	}

function ClearForm()
    {
	document.myForm.SubFirstName.value = '';
	document.myForm.SubLastName.value = '';
	document.myForm.SubAddress.value = '';
	document.myForm.SubEmail.value = '';
	document.myForm.SubPhone.value = '';
	document.myForm.SubTown.value = '';
	document.myForm.SubState.value = '';
	document.myForm.SubZip.value = '';
	document.myForm.SubAmount.value = '$0.00';
	}

function ResetForm()
    {
	document.myForm.SubFirstName.value = document.myForm.SubFirstName.defaultValue;
	document.myForm.SubLastName.value =	document.myForm.SubLastName.defaultValue;
	document.myForm.SubAddress.value = document.myForm.SubAddress.defaultValue;
	document.myForm.SubEmail.value = document.myForm.SubEmail.defaultValue;
	document.myForm.SubPhone.value = document.myForm.SubPhone.defaultValue;
	document.myForm.SubTown.value = document.myForm.SubTown.defaultValue;
	document.myForm.SubState.value = document.myForm.SubState.defaultValue;
	document.myForm.SubZip.value = document.myForm.SubZip.defaultValue;
	document.myForm.SubAmount.value = document.myForm.SubAmount.defaultValue;
	}

var content=new Array()
content[0]='<input class="button" type="button" onClick="ClearForm();  changetext(content[1]);" value="Clear Form">'
content[1]='<input class="button" type="reset" onClick=" changetext(content[0]); ResetForm();" value="Get My Profile">'

function changetext(whichcontent)
	{
	if (document.all)
		descriptions.innerHTML=whichcontent
	else if (document.layers)
		{
		document.d1.document.d2.document.write(whichcontent)
		document.d1.document.d2.document.close()
		}

	}