//SETTINGS.
//The display style of the normal visible state of web page elements
//which are toggled by the toggleVisibility() function.  This can be changed
//anywhere in your page or script by setting it to one of the other options.
// Options: 
//   '' = default
//   'inline' = normal flow layout
//   'block' = forced line break before and after drawing the element.
var tv_NormalState = ''; 


//FUNCTIONS.
//Function to toggle the visibility of an HTML element 
//whose ID is passed as a parameter to this function.
function toggleVisibility(id) {

   var currentState = document.getElementById(id).style.display;
   if ( currentState == 'none' ) document.getElementById(id).style.display = tv_NormalState;
	 else document.getElementById(id).style.display = 'none';
	 
}


function togText(boxNumber) {

var expanded = eval("expanded"+boxNumber);
var id = eval("box"+boxNumber);
var currentText = document.getElementById(id).innerHTML;
if ( expanded ) {

	document.getElementById(id).innerHTML = "LESS";
	eval("expanded"+boxNumber) = false;

} else {

	document.getElementById(id).innerHTML = "READ";
	eval("expanded"+boxNumber) = true;

}
/*
<div id='box1'><a onclick='javascript: togText(1); return false;'>MORE</a></div><script language="JavaScript" type="text/javascript">
<!--
var expanded1 = false;
//-->
</script>
*/


//Function to preload an image into memory for quicker swapout later.  Call
        //this fuction in the <head> of your HTML document. 
        function loadImage(url) {
        	var temp = new Image();
        	temp.src = url;
        }

//Function to change an image named {name} to use the image at {URL}.
        function swapImage(name,url) {
        	document[name].src=url;
        }






