function ShowFeature( asFeature, asFeatureLabel )
{

  //0.  Set the Label at the top of the feature window.

  elemFeatureTitle = document.getElementById( "divFeatureTitle" );
  elemFeatureTitle.innerHTML = "<font class=\"menuTitleFont\">" + asFeatureLabel + "</font>";


  //1.  Hook the Outer DIV and move it into position.

  elemOuter = document.getElementById( "divFeatures" );
  elemOuter.style.display = "block";


  //1a.  Set the left edge.

  var liWindowWidth = GetClientWidth();
  liWindowWidth = ( ( liWindowWidth - 870 ) / 2 ) + 25

  elemOuter.style.left = liWindowWidth ;

  //1b. Set the top edge.

  var liWindowHeight = GetClientHeight();
  var liScrollTop = GetScrollTop();

  if ( liWindowHeight > 600 )
    elemOuter.style.top= 85 + liScrollTop;        
  else
    elemOuter.style.top= 5 + liScrollTop;        


  //2.  Load the flash movie into the DIV.

  elem = document.getElementById( "divFeaturesPlayer" );        

  var lsHtml = "<object classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" id=\"features\" width=\"900\" height=\"530\" codebase=\"http://fpdownload.macromedia.com/get/flashplayer/current/swflash.cab\">"
             +   "<param name=\"movie\" value=\"features.swf?FeatureSet=" + asFeature + "\" />"
             +   "<param name=\"quality\" value=\"high\" />"
             +   "<param name=\"bgcolor\" value=\"#869ca7\" />"
             +   "<param name=\"allowScriptAccess\" value=\"sameDomain\" />"
             +   "<embed src=\"features.swf?FeatureSet=" + asFeature + "\" quality=\"high\" bgcolor=\"#869ca7\" "
             +     "width=\"900\" height=\"530\" name=\"features\" align=\"middle\" "
             +     "play=\"true\" "
             +     "loop=\"false\" "
             +     "quality=\"high\" "
             +     "allowScriptAccess=\"sameDomain\" "
             +     "type=\"application/x-shockwave-flash\" "
             +     "pluginspage=\"http://www.adobe.com/go/getflashplayer\"> "
             +   "</embed>"
             + "</object>"; 


  elem.innerHTML = lsHtml;

}


function GetClientWidth() {
	return GetFilterResults(
		window.innerWidth ? window.innerWidth : 0,
		document.documentElement ? document.documentElement.clientWidth : 0,
		document.body ? document.body.clientWidth : 0
	);
}
function GetClientHeight() {
	return GetFilterResults(
		window.innerHeight ? window.innerHeight : 0,
		document.documentElement ? document.documentElement.clientHeight : 0,
		document.body ? document.body.clientHeight : 0
	);
}
function GetScrollLeft() {
	return GetFilterResults(
		window.pageXOffset ? window.pageXOffset : 0,
		document.documentElement ? document.documentElement.scrollLeft : 0,
		document.body ? document.body.scrollLeft : 0
	);
}
function GetScrollTop() {
	return GetFilterResults(
		window.pageYOffset ? window.pageYOffset : 0,
		document.documentElement ? document.documentElement.scrollTop : 0,
		document.body ? document.body.scrollTop : 0
	);
}
function GetFilterResults(n_win, n_docel, n_body) {
	var n_result = n_win ? n_win : 0;
	if (n_docel && (!n_result || (n_result > n_docel)))
		n_result = n_docel;
	return n_body && (!n_result || (n_result > n_body)) ? n_body : n_result;
}

function CloseFeature()
{

  //0.  Clear the Label at the top of the feature window.

  elemFeatureTitle = document.getElementById( "divFeatureTitle" );
  elemFeatureTitle.innerHTML = "";


  //1.  Hook the Outer DIV and hide it.

  elemOuter = document.getElementById( "divFeatures" );
  elemOuter.style.display = "none";


  //2.  Remove flash movie from the DIV.

  elem = document.getElementById( "divFeaturesPlayer" );        
  elem.innerHTML = "";


}