// JavaScript Document
/***********************************************
* Cross browser Marquee II-  Dynamic Drive (www.dynamicdrive.com)
* This notice MUST stay intact for legal use
* Visit http://www.dynamicdrive.com/ for this script and 100s more.
***********************************************/
function Go(loc){
	document.location.href = loc + ".php";	
}
var delayb4scroll=500 //Specify initial delay before marquee starts to scroll on page (2000=2 seconds)
var marqueespeed=1 //Specify marquee scroll speed (larger is faster 1-10)
var pauseit=1 //Pause marquee onMousever (0=no. 1=yes)?

////NO NEED TO EDIT BELOW THIS LINE////////////

var copyspeed=marqueespeed
var pausespeed=(pauseit==0)? copyspeed: 0
var actualheight=''

function scrollmarquee(){
if (parseInt(cross_marquee.style.top)>(actualheight*(-1)+8))
cross_marquee.style.top=parseInt(cross_marquee.style.top)-copyspeed+"px"
else
cross_marquee.style.top=parseInt(marqueeheight)+8+"px"
}

function initializemarquee(){
cross_marquee=document.getElementById("vmarquee")
cross_marquee.style.top=0
marqueeheight=document.getElementById("marqueecontainer").offsetHeight
actualheight=cross_marquee.offsetHeight
//if (window.opera || navigator.userAgent.indexOf("Netscape/7")!=-1){ //if Opera or Netscape 7x, add scrollbars to scroll and exit
//cross_marquee.style.height=marqueeheight+"px"
//cross_marquee.style.overflow="scroll"
//return
//}
setTimeout('lefttime=setInterval("scrollmarquee()",40)', delayb4scroll)
}

// JavaScript Document
// Example: obj = findObj("image1");
function findObj(theObj, theDoc)
{
  var p, i, foundObj;
  
  if(!theDoc) theDoc = document;
  if( (p = theObj.indexOf("?")) > 0 && parent.frames.length)
  {
    theDoc = parent.frames[theObj.substring(p+1)].document;
    theObj = theObj.substring(0,p);
  }
  if(!(foundObj = theDoc[theObj]) && theDoc.all) foundObj = theDoc.all[theObj];
  for (i=0; !foundObj && i < theDoc.forms.length; i++) 
    foundObj = theDoc.forms[i][theObj];
  for(i=0; !foundObj && theDoc.layers && i < theDoc.layers.length; i++) 
    foundObj = findObj(theObj,theDoc.layers[i].document);
  if(!foundObj && document.getElementById) foundObj = document.getElementById(theObj);
  
  return foundObj;
}

function CheckAll( cForm , indValue , cPattern ) {
	objForm = findObj( cForm ) ;
	for ( i=0 ; i < objForm.length ; i++ ) {
		cString = new String( objForm[i].name );
		if ( cString.indexOf( cPattern ) > -1 ) {
			objForm[i].checked = indValue ;
		}
	}
}

function Toogle( cObj ) {
	obj =  findObj( cObj ) ;		
	if ( obj.style.display == "" ) {
		obj.style.display = "none" ;
	} else {
		obj.style.display = "" ;			
	}
}

function TM_back()  {
	var tm_curr = document.URL;
	if ( tm_curr.indexOf('#') == -1 ) {
		history.back();
	} else {
		history.go(-2);
	}
}