if (ptl) {
	dtitle = "Fairwinds Luxury Homes | " + ptl; 
	document.title = dtitle;
}

function wrtDate() {
	var d = new Date();
	document.write(d.getYear());
}

var iPath = '/vimages/';

function preLoad()
{
  if(document.images)
  {
    var argLen = arguments.length;
    for(var i = 0; i < argLen; i++)
    {
      var arg = arguments[i];
      self[arg] = new Image();
      self[arg].src = iPath + arg;
    }
  }
}

function EmailFormat(eName,eAddress,eText) {
		var ToName = eName;
		var ToAddress = eAddress;
		var ToDisplayText = eText;
		document.write("<a href=\"mailto:"+eName+"@"+ToAddress+"\">"+eText+"</a>");
	}

	function Fo(w,h,ver,path,bgc,sec) {
		var bkg = bgc;
		var section="sec="+sec;
		document.write("<object type=\"application/x-shockwave-flash\" classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" codebase=\"http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version="+ver+",0,0,0\" width=\""+w+"\" height=\""+h+"\">");
		document.write("<param name=movie value=\"" + path + "\" />"); 
   		document.write("<param name=menu value=false />"); 
  		document.write("<param name=quality value=best />"); 
		document.write("<param name=wmode value=transparent />");
		document.write("<param name=FlashVars value=\""+section+"\" />");
		document.write("<param name=scale value=noscale />"); 
  		document.write("<embed src=\"" + path + "\" menu=false scale=noscale quality=best wmode=transparent FlashVars=\""+section+"\" pluginspage=\"http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash\" type=\"application/x-shockwave-flash\" width=\""+w+"\" height=\""+h+"\">");
   		document.write("</embed></object>"); 
		}	
		
function FoSWF(w,h,ver,path,targetdiv,sec) {
	var section="sec="+sec;
	var DisplayFlash = document.getElementById(targetdiv);
	
	var str = "<object type=\"application/x-shockwave-flash\" classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" codebase=\"http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version="+ver+",0,0,0\" width=\""+w+"\" height=\""+h+"\">";
	str += "<param name=movie value=\"" + path + "\" />"; 
  	str += "<param name=menu value=false />"; 
 	str += "<param name=quality value=best />"; 
	str += "<param name=wmode value=transparent />";
	str += "<param name=FlashVars value=\""+section+"\" />";
	str += "<param name=scale value=noscale />"; 
 	str += "<embed src=\"" + path + "\" menu=false scale=noscale quality=best wmode=transparent FlashVars=\""+section+"\" pluginspage=\"http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash\" type=\"application/x-shockwave-flash\" width=\""+w+"\" height=\""+h+"\">";
  	str += "</embed></object>"; 
	DisplayFlash.innerHTML = str;
}	
		
		
function FoHome(w,h,ver,path,bgc) {
		var bkg = bgc;
		document.write("<object type=\"application/x-shockwave-flash\" classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" codebase=\"http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version="+ver+",0,0,0\" width=\""+w+"\" height=\""+h+"\">");
		document.write("<param name=movie value=\"" + path + "\" />"); 
   		document.write("<param name=menu value=false />"); 
  		document.write("<param name=quality value=best />"); 
		document.write("<param name=wmode value=transparent />");
		document.write("<param name=scale value=noscale />"); 
  		document.write("<embed src=\"" + path + "\" menu=false scale=noscale quality=best wmode=transparent pluginspage=\"http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash\" type=\"application/x-shockwave-flash\" width=\""+w+"\" height=\""+h+"\">"); 
   		document.write("</embed></object>"); 
		}		

function pTitle() {
	//window.location.reload();
	document.getElementById('pagetitle').innerHTML = "<img src=\"/vimages/ptitle_"+ sec +".gif\" alt=\"" + ptl + "\" />";
}

function ForImages() 
	{
	var iPath = '/feature/3747ashton/';
	var iExt = '.jpg';
	if(document.images)
	  {
	    var argLen = arguments.length;
	    for(var i = 0; i < argLen; i++)
	    {
	      var arg = arguments[i];
	      self[arg] = new Image();
	      self[arg].src = iPath + arg + iExt;

		  var imgFullSize = iPath + arg + iExt;
		  var imgThumbName = iPath + arg + "_th" + iExt;
		  //First to Load 
		  var imgFullSizeFirst = iPath + arguments[0] + iExt;
		  		
		  document.write("<div><a class=\"pfsthumbs\" href=\"#\" onmouseover=\"SwapImage('" + imgFullSize + "')\"><img class=\"pfs_th\" src='" + imgThumbName + "' width=\"50\" height=\"33\"/></a></div>");  
	    }
	  }
	  document.getElementById('picmain').innerHTML = "<img src='"+imgFullSizeFirst+"' />";
	}
	
//Swap
function SwapImage(imgpath) {
	document.getElementById('picmain').innerHTML = "<img src='"+imgpath+"' />";
	}	
