// JavaScript Document

function DisplayEmailLink1 () {
	document.write("<a href='mailto:");
	document.write("admin@");
	document.write("blueprintinteriors.com.au");
	document.write("'>");
	document.write("admin@");
	document.write("blueprintinteriors.com.au");
	document.write("</a>");
}

function DisplayEmailLink_Generic (name, domain) {
	document.write("<a href='mailto:");
	document.write(name + "@");
	document.write(domain);
	document.write("'>");
	document.write(name + "@");
	document.write(domain);
	document.write("</a>");
}

function DisplayEmailLink_Generic1 (name, domain) {
	document.write("<a href='mailto:");
	document.write(name + "@");
	document.write(domain);
	document.write("'>");
}

function DisplayEmailLink_Generic2 (text) {
	document.write(text);
	document.write("</a>");
}

function checkClientSize()
{

	//Check for window size below 768px high
	if ((getClientHeight() <= 600) || (getClientWidth() <= 1024))
	{
//	alert (getClientWidth());
//	alert (getClientHeight());
		document.getElementById("header-container").style.position = "relative";
		if (document.getElementById("content-container") != undefined)
		{
			document.getElementById("content-container").style.paddingTop = "0px";
			HeaderScrollStatus = "NP_SH";
		}
		else
		{
			document.getElementById("content-container-gallery").style.paddingTop = "0px";
			HeaderScrollStatus = "GP_SH";
		}
//		document.getElementById("headerlogo-container").style.position = "relative";
//		document.getElementById("headerlogo-container").style.textAlign = "relative";
//		document.getElementById("headerlogo-container").style.paddingLeft = 206;
	}
	else
	{
		if (document.getElementById("content-container") != undefined)
		{
			// Check for IE6
			if (navigator.appVersion.match("MSIE 6.0") == "MSIE 6.0")
			{
				HeaderScrollStatus = "NP_SH";
			}
			else
			{
				HeaderScrollStatus = "NP_FH";
			}
		}
		else
		{
			// Check for IE6
			if (navigator.appVersion.match("MSIE 6.0") == "MSIE 6.0")
			{
				HeaderScrollStatus = "GP_SH";
			}
			else
			{
				HeaderScrollStatus = "GP_FH";
			}
		}
	}

}

function getClientWidth()
{
	
	var w;

	if(document.innerWidth)
	{
		w=document.innerWidth;
	} 
	else if(document.documentElement.clientWidth)
	{
		w=document.documentElement.clientWidth;
	} 
	else if(document.body)
	{
		w=document.body.clientWidth; 
	}
	
	return w;
	
}

function getClientHeight()
{

	var h;
	
	if(document.innerHeight)
	{
		h=document.innerHeight;
	} 
	else if(document.documentElement.clientHeight)
	{
		h=document.documentElement.clientHeight;
	} 
	else if(document.body)
	{
		h=document.body.clientHeight; 
	}
	
	return h;
	
}

function checkContact()
{
   if (document.getElementById("FirstName").value == "")
   {
      alert("You must enter your first name");
      return false;
   }
   if (document.getElementById("LastName").value == "")
   {
      alert("You must enter your last name");
      return false;
   }
   if (document.getElementById("EmailAddress").value == "")
   {
      alert("You must enter your email address");
      return false;
   }
   if (document.getElementById("HomePhone").value == "")
   {
      alert("You must enter your home phone number");
      return false;
   }
   if (document.getElementById("CellPhone").value == "")
   {
      alert("You must enter your mobile phone number");
      return false;
   }
   return true;
}
