// JavaScript Document


// function showTVad(), at start css style is set to none, javascript resets it to block

function showTVad(){

var target1 = document.getElementById("hpContentWrapper");
var target2 = document.getElementById("hpContentWrapper2");
//target1.style.display = 'none';
target2.style.display = 'block';

} // eof showTVad()

function hideTVad(){

var target1 = document.getElementById("hpContentWrapper");
var target2 = document.getElementById("hpContentWrapper2");
//target1.style.display = 'block';
target2.style.display = 'none';
} // eof hideTVad()

function randomHpImage() {

// randomly select a background image and assign it to the html element class
// so the image appears in large preview area (it's a background image)

// array holding background images
var images = new Array(
	"hpimage2.jpg",
	//"hpimage1.jpg",
	//"hpimage3.jpg",
	"hpimage4.jpg",
	"hpimage5.jpg",
	//"hpimage6.jpg",
	//"hpimage7.jpg",
	"hpimage8.jpg",
	"hpimage9.jpg"
);

var randValue = Math.floor(Math.random() * images.length); // random # between 0 and length of array
var bgImage = "url(/images/hp/" + images[randValue] + ")"; // setting the background-image: ???
var target1 = document.getElementById("hpContentWrapper"); // targetting elements to apply background to
target1.style.backgroundImage = bgImage; // setting the background image


} // eof randomHpImage


// this script helps javascript to interact with the flash movie.
<!-- no script
function playmovie(flag,video) {
	if (flag == 1) { 
		document.getElementById(video).TGotoLabel("/", "start");
	} else if (flag == 0) {
		document.getElementById(video).TGotoLabel("/", "end");
	}
}
-->
