// create arrays for normal images and 'on' images


// add all new navigation images to these arrays


/* image names (not file names) must be the same name as the file name or directory the


content lives in */


var imagesoff = new Array()


	imagesoff['meetnow'] = '/images/home/1nav_home_meetnow.gif'


	imagesoff['signup'] = '/images/home/1nav_home_signup.gif'


	imagesoff['conferencing'] = '/images/home/1nav_home_conferencing.gif'


	imagesoff['help'] = '/images/home/1nav_home_help.gif'


	imagesoff['aboutus'] = '/images/home/1nav_home_aboutus.gif'





	imagesoff['start'] = '/images/home/c2a_start.gif'


	imagesoff['join'] = '/images/home/c2a_join.gif'


	imagesoff['demo'] = '/images/home/c2a_demo.gif'


	imagesoff['casignup'] = '/images/home/c2a_signup.gif'








var imageson = new Array()	


	imageson['meetnow'] = '/images/home/1nav_home_meetnow_on.gif'


	imageson['signup'] = '/images/home/1nav_home_signup_on.gif'


	imageson['conferencing'] = '/images/home/1nav_home_conferencing_on.gif'


	imageson['help'] = '/images/home/1nav_home_help_on.gif'


	imageson['aboutus'] = '/images/home/1nav_home_aboutus_on.gif'


	


	imageson['start'] = '/images/home/c2a_start_on.gif'


	imageson['join'] = '/images/home/c2a_join_on.gif'


	imageson['demo'] = '/images/home/c2a_demo_on.gif'


	imageson['casignup'] = '/images/home/c2a_signup_on.gif'








/********************************************************************************************


**************************  DON'T EDIT  *****************************************************


********************************************************************************************/


// preload the 'on' images and create an array of preloaded images - 


var imageson_l = new Array()





for(var i=0; i < imageson_l.length; i++) {


	imageson_l[i] = new Image();


	imageson_l[i].src = imageson[i];


}








// image swapping functions


function swapImageOn(name) {


	if( imageson[name] != "") {


		eval("document." + name + ".src" + " = '" + imageson[name] + "'");


	}


}





function swapImageOff(name) {


	if( imagesoff[name] != "") {


		eval("document." + name + ".src" + " = '" + imagesoff[name] + "'");


	}


}





/********************************************************************************************


*********************************************************************************************


********************************************************************************************/





/*******************************************************************************************


*show************************ RANDOM FUNCTIONS - ADD TO AS NEEDED  *****************************


*******************************************************************************************/





// window poping functions


function popdemowindow(height,width,path) {


  mywindow=window.open(path, 'mywindow','scrollbars=no,resizable=no,height=' + height + ',width=' + width);


  mywindow.focus();


}





function popscrollwindow(height,width,path) {


  mywindow=window.open(path, 'mywindow','scrollbars=yes,resizable=yes,height=' + height + ',width=' + width);


  mywindow.focus();


}








// cookie setting and reading functions - for use in playing the swoosh 


var playit="true"





function setCookie() {


	document.cookie="heardit=yes";


}





function findCookie() {


	allcookies = document.cookie;


	cookielist = allcookies.split(";");


	for(i=0; i < cookielist.length; i++) {


		if(cookielist[i].indexOf("heardit=yes") != -1) {


			playit = 'false';


		}


	}


}





// test to see if the cookie has been set and then play or don't play the flash


function playSwoosh() {


	findCookie(); 


	if(playit != 'false') 


   {


			if (!redirectPage) {		// if dynamic embedding is turned on


				if(hasCorrectVersion) {	// if we've detected an acceptable version


					var oeTags = '<OBJECT CLASSID="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"'


					+ 'WIDTH="18" HEIGHT="18"'


					+ 'CODEBASE="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab">'


					+ '<PARAM NAME="MOVIE" VALUE="swoosh.swf">'


					+ '<PARAM NAME="PLAY" VALUE="true">'


					+ '<PARAM NAME="LOOP" VALUE="false">'


					+ '<PARAM NAME="QUALITY" VALUE="high">'


					+ '<PARAM NAME="MENU" VALUE="false">'
					+ '<PARAM NAME="BGCOLOR" VALUE="ffcf31">'


					+ '<EMBED SRC="swoosh.swf"'


					+ 'WIDTH="18" HEIGHT="18"'


					+ 'PLAY="true"'


					+ 'LOOP="false"'


					+ 'QUALITY="high"'


					+ 'MENU="false"'
					+ 'BGCOLOR="ffcf31"'


					+ 'TYPE="application/x-shockwave-flash"'


					+ 'PLUGINSPAGE="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash">'


					+ '</EMBED>'


					+ '</OBJECT>';


					


					document.write(oeTags); 	// embed the flash movie


				} 


			}





		setCookie(); 


	}


}








// stuff involved in popping the new name and split screen windows


var popit = "true";


var redirectVal;





function popnewnamewin() {


	if(popit != "false" && redirectVal == "evoke") {


		window.open('/newname.asp','mywindow', 'width=500,height=525');


	}


}





function popsplitwin() {


	if(window.location.href.indexOf('evoke.com') != -1) {


	if(getsite == "") {


		window.open('/split.asp','mywindow','width=326,height=297');


		}


	}


}





//demo link finctions


function openInParent(path) {


	window.opener.location.href="'" + path + "'";


	window.blur();


	}





function openHelp() {


	window.open('/help/qrg_wc_main.asp','helpWindow','width=700 height=500');


	window.blur();


	}








// function to record any action to a log file


function set(banner, comp) {


   date = new Date();


   counter = new Image();


   random_number = date.getSeconds() + date.getYear() + date.getMonth() + date.getDay();


   counter.src='http://www.mobile.evoke.com/scripts/EcSet.php3?set=' + banner + 


               '&time=' + date + '&comp=' + comp + '&random=' + random_number;


}














  


/*******************************************************************************************


*********************** FLASH DETECTION - DO NOT EDIT **************************************


*******************************************************************************************/


// --------------------------------------------


// user defined global variables - customize for inspection behaviour





var reqVerNum = 4;			// version the user needs to view site (min is 2, max is 5)


var redirectPage = false; 			// "true" loads new flash or non-flash page into browser


									// "false" embeds movie or alternate html code into current page





// set next three vars if redirectPage is true...


var moviePage = "movie.html"		// the location of the SWF movie page


var nomoviePage = "noflash.html"	// send user here if they don't have the plugin or we can't detect it


var upgradePage = "upgrade.html"	// send user here if we detect an old plugin


// --------------------------------------------











// -------------


// everything below this point is internal until after the body tag


// do not edit! 


// -------------





// system globals


var ver2Installed = false;		// boolean. true if flash 2 is installed


var ver3Installed = false;		// boolean. true if flash 3 is installed


var ver4Installed = false;		// boolean. true if flash 4 is installed


var ver5Installed = false;		// boolean. true if flash 5 is installed


var maxVersion = 5;					// highest version we can actually detect


var actualVersion = 0;				// version the user really has


var hasCorrectVersion = false;		// boolean. true if it is safe to embed the flash movie in the page


var jsVersion = 1.0;				// the version of javascript supported








// detect the browser...we're looking for ie/win


var isIE = (navigator.appVersion.indexOf("MSIE") != -1) ? true : false;		// true if we're on ie


var isWin = (navigator.appVersion.indexOf("Windows") != -1) ? true : false; // true if we're on windows





// this is a js1.1 code block, so make note that js1.1 is supported.


jsVersion = 1.1;





// write vbscript detection if we're not on macintosh.


if(isIE && isWin){ // don't write vbscript tags on anything but ie win


	document.write('<SCR' + 'IPT LANGUAGE=VBScript\> \n');


	document.write('on error resume next \n');


	document.write('ver2Installed = (IsObject(CreateObject("ShockwaveFlash.ShockwaveFlash.2"))) \n');


	document.write('ver3Installed = (IsObject(CreateObject("ShockwaveFlash.ShockwaveFlash.3"))) \n');


	document.write('ver4Installed = (IsObject(CreateObject("ShockwaveFlash.ShockwaveFlash.4"))) \n');


	document.write('ver5Installed = (IsObject(CreateObject("ShockwaveFlash.ShockwaveFlash.5"))) \n');	


	document.write('</SCR' + 'IPT\> \n'); // break up end tag so it doesn't end our script


}





// next comes the standard javascript detection that uses the navigator.plugins array


// we pack the detector into a function so it loads before we run it





function findFlash(){	





	if (navigator.plugins){								// does navigator.plugins exist?


		if (navigator.plugins["Shockwave Flash 2.0"] 	// yes>> then is Flash 2 


		|| navigator.plugins["Shockwave Flash"]){		// or flash 3+ installed?





			// set convenient references to flash 2 and the plugin description


			var isVersion2 = navigator.plugins["Shockwave Flash 2.0"] ? " 2.0" : "";


			var flashDescription = navigator.plugins["Shockwave Flash" + isVersion2].description;


			// a flash plugin-description looks like this: Shockwave Flash 4.0 r5


			// so we can get the major version by grabbing the character before the period


			// note that we don't bother with minor version detection. do that in your movie with $version


			var flashVersion = parseInt(flashDescription.charAt(flashDescription.indexOf(".") - 1));





			// we know the version, now set appropriate version flags


			ver2Installed = flashVersion == 2;		


			ver3Installed = flashVersion == 3;


			ver4Installed = flashVersion == 4;


			ver5Installed = flashVersion == 5;


		}


	}


	


	// loop through all versions we're checking, and set actualVersion to highest detected version


	for (var i = 2; i <= maxVersion; i++) {	


		if (eval("ver" + i + "Installed") == true) actualVersion = i;


	}


	// if we're on webtv, the version supported is 2 (pre-summer2000, or 3, post-summer2000)


	// note that we don't bother sniffing varieties of webtv. you could if you were sadistic...


	if(navigator.userAgent.indexOf("WebTV") != -1) actualVersion = 2;	


	


	// uncomment next line to display flash version during testing


	// alert("version detected: " + actualVersion);








	// we're finished getting the version. time to take the appropriate action





	if (actualVersion >= reqVerNum) { 		// user has a new enough version


		hasCorrectVersion = true;						// flag: it's okay to write out the object/embed tags later





		if (redirectPage) {							// if the redirection option is on, load the flash page


			if(jsVersion > 1.0) {					// need javascript1.1 to do location.replace


				window.location.replace(moviePage);	// use replace() so we don't break the back button


			} else {


				window.location = moviePage;		// otherwise, use .location


			}


		}


	} else {	// user doesn't have a new enough version.


	


		if (redirectPage) {		// if the redirection option is on, load the appropriate alternate page


			if(jsVersion > 1.0) {	// need javascript1.1 to do location.replace


				window.location.replace((actualVersion >= 2) ? upgradePage : nomoviePage);


			} else {


				window.location = (actualVersion >= 2) ? upgradePage : nomoviePage;


			}


		}


	}


}








findFlash();	// call our detector now that it's safely loaded.	


	


/*******************************************************************************************


********************************* End Flash Detection  *************************************


*******************************************************************************************/














