// Copyright © 2008 Formative Innovations Inc. All Rights Reserved.
// The content contained within this file is both confidential and privileged. 
// You are hereby notified that any review, retransmission, conversion to hard copy, copying, circulation
// or other use of the content contained within this file is strictly prohibited.















































































































































































































































































































function ResizeHeight(height)
{
   try
   {
	var div_id = "flash";
	    
        if (window.innerHeight)
	{
	       	//MOZILLA
	       	if(window.innerHeight < height)
	       	{
			document.getElementById(div_id).style.height = height + "px";
	    	}
		else
		{
		 	document.getElementById(div_id).style.height = window.innerHeight + "px";
		}
	}
	else if (document.documentElement && document.documentElement.clientHeight)
	{
	
		if(document.documentElement.clientHeight < height)
		{
			document.getElementById(div_id).style.height = height + "px";
		}
		else
		{
			document.getElementById(div_id).style.height = document.documentElement.clientHeight + "px";
		}
	}
	else if (document.body)
	{
	        //IE 7
		if(document.body.clientHeight < height)
		{
			document.getElementById(div_id).style.height = height + "px";
		}
		else
		{
			document.getElementById(div_id).style.height = document.body.clientHeight + "px";
		}
		
	}
	else
	{
		if(window.innerHeight < height)
		{
			document.getElementById(div_id).style.height = height + "px";
		}
		else
		{
			document.getElementById(div_id).style.height = window.innerHeight + "px";
		}
		
	}
    }
    catch(Exception)
    {
	alert('ResizeHeight() Exception: ' + Exception.description);
    }
}

function ResizeWidth(width)
{
   try
   {
	var div_id = "flash";
	    
        if (window.innerWidth)
	{
	    	//MOZILLA		
	
		if(window.innerWidth < width)
		{
		    	document.getElementById(div_id).style.width = width + "px";
		}
		else
		{
			document.getElementById(div_id).style.width = window.innerWidth + "px";
		}
	}
	else if (document.documentElement && document.documentElement.clientWidth)
	{		
			
		if(document.documentElement.clientWidth < width)
		{
			document.getElementById(div_id).style.width = width + "px";
		}
		else
		{
			document.getElementById(div_id).style.width = document.documentElement.clientWidth + "px";
		}
	}
	else if (document.body)
	{
	    	//IE 7				
		if(document.body.clientWidth < width)
		{
			document.getElementById(div_id).style.width = width + "px";
		}
		else
		{
			document.getElementById(div_id).style.width = document.body.clientWidth + "px";
		}
	}
	else
	{	
		
		if(window.innerWidth < width)
		{
			document.getElementById(div_id).style.width = width + "px";
		}
		else
		{
			document.getElementById(div_id).style.width = window.innerWidth + "px";
		}
	}
   }
   catch(Exception)
   {
       alert('ResizeWidth() Exception: ' + Exception.description);
   }
}

function ResizeElementHeight(div_id, height)
{
   try
   {
	    
        if (window.innerHeight)
	{
	       	//MOZILLA
	       	if(window.innerHeight < height)
	       	{
			document.getElementById(div_id).style.height = height + "px";
	    	}
		else
		{
		 	document.getElementById(div_id).style.height = window.innerHeight + "px";
		}
	}
	else if (document.documentElement && document.documentElement.clientHeight)
	{
	
		if(document.documentElement.clientHeight < height)
		{
			document.getElementById(div_id).style.height = height + "px";
		}
		else
		{
			document.getElementById(div_id).style.height = document.documentElement.clientHeight + "px";
		}
	}
	else if (document.body)
	{
	        //IE 7
		if(document.body.clientHeight < height)
		{
			document.getElementById(div_id).style.height = height + "px";
		}
		else
		{
			document.getElementById(div_id).style.height = document.body.clientHeight + "px";
		}
		
	}
	else
	{
		if(window.innerHeight < height)
		{
			document.getElementById(div_id).style.height = height + "px";
		}
		else
		{
			document.getElementById(div_id).style.height = window.innerHeight + "px";
		}
		
	}
    }
    catch(Exception)
    {
	alert(Exception.description);
    }
}

function ResizeElementWidth(div_id, width)
{
   try
   {
	    
        if (window.innerWidth)
	{
	    	//MOZILLA		
	
		if(window.innerWidth < width)
		{
		    	document.getElementById(div_id).style.width = width + "px";
		}
		else
		{
			document.getElementById(div_id).style.width = window.innerWidth + "px";
		}
	}
	else if (document.documentElement && document.documentElement.clientWidth)
	{		
			
		if(document.documentElement.clientWidth < width)
		{
			document.getElementById(div_id).style.width = width + "px";
		}
		else
		{
			document.getElementById(div_id).style.width = document.documentElement.clientWidth + "px";
		}
	}
	else if (document.body)
	{
	    	//IE 7				
		if(document.body.clientWidth < width)
		{
			document.getElementById(div_id).style.width = width + "px";
		}
		else
		{
			document.getElementById(div_id).style.width = document.body.clientWidth + "px";
		}
	}
	else
	{	
		
		if(window.innerWidth < width)
		{
			document.getElementById(div_id).style.width = width + "px";
		}
		else
		{
			document.getElementById(div_id).style.width = window.innerWidth + "px";
		}
	}
   }
   catch(Exception)
   {
       alert(Exception.description);
   }
}


function ScrollTo(target)
{
   try
   {
	var is_number = parseInt(target, 10);

	if(window.innerHeight)
	{
	
	    if(isNaN(is_number))
	    {  			
	       if (target.toUpperCase() == "TOP")
	       { window.scrollTo(0,0);	}
	       else if (target.toUpperCase() == "BOTTOM")
	       { window.scrollTo(0, window.innerHeight); }
	    }
	    else { window.scrollTo(0, target); }
	}
	else
	{
	   if(isNaN(is_number))
	   {  
	       if (target.toUpperCase() == "TOP")
	       {window.scrollTo(0,0);}
	       else if (target.toUpperCase() == "BOTTOM")
	       {window.scrollTo(0,50000);} 	
	   }
	   else { window.scrollTo(0, target); }
	}
	
    }
    catch(Exception)
    {
      alert('ScrollTo() Exception: ' + Exception.description);
    }

}


function ResetElementSize(div_id)
{
   
   try
   {	
     if(document.getElementById(div_id) != "undefined")
     {
	var tempw = document.getElementById(div_id).style.width;
        var temph = document.getElementById(div_id).style.height;

        var div_width = tempw.split("px");
	var div_height = temph.split("px");

	if(window.innerWidth)
     	{

	   if(window.innerWidth > div_width[0])
	   {
	      document.getElementById(div_id).style.width = "100%";
           }
	   
 	   if(window.innerHeight > div_height[0])
	   {
	      document.getElementById(div_id).style.height = "100%";
           }

	}
	else if (document.documentElement && document.documentElement.clientWidth)
	{
		
	   if(document.documentElement.clientWidth > div_width[0])
	   {
              document.getElementById(div_id).style.width = "100%";
           }
	   
 	   if(document.documentElement.clientHeight > div_height[0])
	   {
	      document.getElementById(div_id).style.height = "100%";
           }
	}
	else if (document.body)
	{
	   if(document.body.clientWidth > div_width[0])
	   {
	      document.getElementById(div_id).style.width = "100%";
           }
	   
 	   if(document.body.clientHeight > div_height[0])
	   {
	      document.getElementById(div_id).style.height = "100%";
           }
	
	}	
     }
   }
   catch(Exception)
   {
	alert('ResetElementSize() Exception: ' + Exception.description);	
   }
}




































































































































































































































































































