// JavaScript Document
// functionsendmail.js
var attach = false;

function sendmail(theframe,themessage){
	var location = "/ajax/response.php?themessage=" + themessage;
	theframe.processajax("message",location);
}


function sendThis(value){
	//Submit the form
	value.submit();
	setStatus("Sending...","message");
}

function setStatus(theStatus, theObj){
	obj = document.getElementById(theObj);
	if(obj){
		obj.innerHTML = "<div class=\"bold\">" + theStatus + "</div>";
	}
}

function killText(){
var obj = document.getElementById("message");
obj.innerHTML = "";
}

function goattach(){
	if(attach == false){
		attach = true;
		var obj = document.getElementById('destroy');
		obj.style.display = "block";
		var msg = '<iframe name="extraupload" class="theframe" id="extraupload" src="/uu_file_upload.php"></iframe>';
		obj.innerHTML = msg;
	}
	else {
		attach = false;
		var obj = document.getElementById('destroy');
		obj.style.display = "none";
		obj.innerHTML = "";
		enableForm();
	}
}

function goupload(){
	var location = "http://www.hsproducts.com/uu_file_upload.php";
	processajax("extraupload",location);
	
}

function closeWin(){
var obj = document.getElementById('destroy');
obj.style.display = "none";
sendName();
}

function startCountdown(){
var it = setTimeout("firemessage()",1000);
}