function SetupContact(website_description)
{
	document.write("<a href=\"mailto:info@heritagecommunityfdn.org?Subject="+website_description+" Web Site\" title=\"Contact us by Email\">Contact us by Email</a>");
}

//function that swaps pictures
function Switch(imgName,imgObjName) 
{
  if (document.images) 
  {
   document.images[imgName].src = eval(imgObjName + ".src");
  }
}

//Function to open new windows
function openWin(URL, Width, Height)
{

aWindow=window.open(URL,"PopUp","width="+Width+",height="+Height+",resizable=yes,scrollbars=yes,left=100,top=60");
    
    aWindow.resizeTo(Width, Height);
    
    aWindow.focus();
    if(aWindow.opener == null)
    {
        aWindow.opener = window;
        aWindow.opener.name = "opener";
    }

}

//Function to pop up windows for images.
function Imgpop(level,szImgSource,szDescription,nCopyrightNum,nSubject,nDate,nUniqueID,nSource)
{
	 
	 popSource			= szImgSource;
	 popSourcePlace 	= nSource;
	 popDescription		= szDescription
	 popCopyright 		= nCopyrightNum;
	 popSubject			= nSubject;
	 popDate			= nDate;
	 popUniqueID		= nUniqueID;

if (popSourcePlace == null)	{ popSourcePlace = ""; }
if (popSubject == null)		{ popSubject = ""; }
if (popDate == null)		{ popDate = ""; }
if (popUniqueID == null)	{ popUniqueID = ""; }

    if (popDescription == "description")
			popDescription = "";
			width=650;
			height=750;

    //If resolution is 640x480
    if(screen.width < 800)
        height=350;
    //If resolution is 800x600
    else if(screen.width < 1024)
        height=500;

    if(level==0)
        openWin("popup.html",width,height);
    
    else if(level==1)
        openWin("../en/popup.html",width,height);

    else if(level==2)
        openWin("../fr/popup.html",width,height);

    else if(level==3)
        openWin("../popup.html",width,height);
}

//Function to pop up windows for footnotes.
function openFootnote(level,szDescription)
{
    popDescription = szDescription;
 
    if (popDescription == "description")
        popDescription = "";
    
    width=360;
    height=150;

    if(level==0)
        openWin("footnote.html",width,height);
    
    else if(level==1)
        openWin("../footnote.html",width,height);

    else if(level==2)
        openWin("../../footnote.html",width,height);
}