<!----------- // begin JavaScript Library

//================Image Swaps ================================

function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}


//================Window Pop ================================
 
  
		function openlink(URL,Wvar,Hvar,Scrollvar,Resize)
		{
		var message = URL + " " + Wvar + " " + Hvar + " " + Scrollvar + " " + Resize;
        if (Resize == null)
        {
                Resize = "resizable=1";
        }
        else
        {
                Resize = "resizable=" + Resize;
        }
                windowattributes='toolbar=no,menubar=0,status=0,copyhistory=-1,scrollbars=' + Scrollvar + ',' + Resize + ',location=0,width=' + Wvar + ',height=' + Hvar + '';
                NewWindow = window.open(URL,"_blank",windowattributes) 
                NewWindow.location = URL;
		}
		

//================Email to friend ================================
 
  
var good;
function checkEmailAddress(field) {
// the following expression must be all on one line...
var goodEmail = field.value.match(/\b(^(\S+@).+((\.com)|(\.net)|(\.edu)|(\.mil)|(\.gov)|(\.org)|(\..{2,2}))$)\b/gi);
if (goodEmail) {
good = true;
}
else {
alert('Please enter a valid e-mail address.');
field.focus();
field.select();
good = false;
   }
}
u = window.location;
m = "I thought this might interest you...";
function mailThisUrl() {
good = false
checkEmailAddress(document.eMailer.address);
if (good) {
// the following expression must be all on one line...
window.location = "mailto:"+document.eMailer.address.value+"?subject="+m+"&body="+document.title+" "+u;
   }
}
		
//=================================================

function topnav (section)

//=================================================
{

	document.write(

'<table width="623" height="46" border="0" cellpadding="0" cellspacing="0" align="center">',
'<!-- flag banner -->',
'<tr>', 
'<td><img src="http://www.cfif.org/htdocs/Images/nav/flag.gif" width="623" height="46" border="0" usemap="#TopBanner"></td></tr>',
'<map name="TopBanner"><area shape="rect" coords="345,1,625,47" href="http://www.cfif.org/"></map>',
'<tr bgcolor="#333366">',
'<!-- top_nav-->',
'<td width="100%" height="16">',
'<table border="0" cellpadding="6" cellspacing="0" width="100%">',
'<tr>',                
'<td><div align="justify">'

// turns on active top link by page visited...

);

	if (section == "about")
	{
		document.write (
			'&nbsp;<b><a class="navTopon" href="http://www.cfif.org/htdocs/about_cfif/index.htm">About CFIF</a>'
		);
	}
	else
	{
		document.write (
			'&nbsp;<b><a class="navTop" href="http://www.cfif.org/htdocs/about_cfif/index.htm">About CFIF</a>'
		);
	}
	
document.write (

''

);

	if (section == "freedom")
	{
		document.write (
			'&nbsp;&nbsp;&nbsp;&nbsp; <a class="navTopon" href="http://www.cfif.org/htdocs/freedomline/index.htm">Freedom Line</a>'
		);
	}
	else
	{
		document.write (
			'&nbsp;&nbsp;&nbsp;&nbsp; <a class="navTop" href="http://www.cfif.org/htdocs/freedomline/index.htm">Freedom Line</a>'
		);
	}
	
document.write (

''

);

	if (section == "legal")
	{
		document.write (
			'&nbsp;&nbsp;&nbsp;&nbsp; <a class="navTopon" href="http://www.cfif.org/htdocs/legal_issues/index.htm">Legal Issues</a>'
		);
	}
	else
	{
		document.write (
			'&nbsp;&nbsp;&nbsp;&nbsp; <a class="navTop" href="http://www.cfif.org/htdocs/legal_issues/index.htm">Legal Issues</a>'
		);
	}
	
document.write (
				
''


);

	if (section == "legislative")
	{
		document.write (
			'&nbsp;&nbsp;&nbsp;&nbsp; <a class="navTopon" href="http://www.cfif.org/htdocs/legislative_issues/index.htm">Legislative Issues</a>'
		);
	}
	else
	{
		document.write (
			'&nbsp;&nbsp;&nbsp;&nbsp; <a class="navTop" href="http://www.cfif.org/htdocs/legislative_issues/index.htm">Legislative Issues</a>'
		);
	}
	
document.write (

'&nbsp;&nbsp;&nbsp;&nbsp; <a class="navTop" href="http://cfif.org/v/index.php/take-action">We The People</a>',
'&nbsp;&nbsp;&nbsp;&nbsp; <a class="navTop" href="http://www.cfif.org/htdocs/about_cfif/donate_to_cfif/donate.htm">Donate</a>',
'&nbsp;&nbsp;&nbsp;&nbsp; <a class="navTop" href="http://www.cfif.org/">Home</a>',
'&nbsp;&nbsp;&nbsp;&nbsp; <a class="navTop" href="http://www.cfif.org/htdocs/search/the_center.htm">Search</a></b>',
'</div>',
'</td>',
'</tr>',
'</table>',
'</td>',
'</tr>',

// begin thin right vertcial bar

'<tr bgcolor="#333366">', 
'<td width="100%"  height="100%" valign="top">'
	);

}

//----->
  
