//////////////////////////////////////////////////////////////////

//																//

//	Weill Cornell Medical College								//

//	nypcancer.org site javascript			    				//

//	nypcancer_new.js											//

//	Version 1.5 												//

//																//

//////////////////////////////////////////////////////////////////

// ::::::::::::::::::::::::::: SECTION I: preload top nav images: three state rollovers
// fill in the absolute paths for all the images

if (browser) {

	one_on= new Image; one_on.src="http://images.med.cornell.edu/headers/navbar/nypcancer/abo_us_on.gif";
	one_off= new Image; one_off.src="http://images.med.cornell.edu/headers/navbar/nypcancer/abo_us_off.gif";
	one_active= new Image; one_active.src="http://images.med.cornell.edu/headers/navbar/nypcancer/abo_us_on.gif";
	
	two_on= new Image; two_on.src="http://images.med.cornell.edu/headers/navbar/nypcancer/hea_ser_on.gif";
	two_off= new Image; two_off.src="http://images.med.cornell.edu/headers/navbar/nypcancer/hea_ser_off.gif";
	two_active= new Image; two_active.src="http://images.med.cornell.edu/headers/navbar/nypcancer/hea_ser_on.gif";
	
	three_on= new Image; three_on.src="http://images.med.cornell.edu/headers/navbar/nypcancer/can_az_on.gif";
	three_off= new Image; three_off.src="http://images.med.cornell.edu/headers/navbar/nypcancer/can_az_off.gif";
	three_active= new Image; three_active.src="http://images.med.cornell.edu/headers/navbar/nypcancer/can_az_on.gif";
	
	four_on= new Image; four_on.src="http://images.med.cornell.edu/headers/navbar/nypcancer/can_pre_on.gif";
	four_off= new Image; four_off.src="http://images.med.cornell.edu/headers/navbar/nypcancer/can_pre_off.gif";
	four_active= new Image; four_active.src="http://images.med.cornell.edu/headers/navbar/nypcancer/can_pre_on.gif";
	
	five_on= new Image; five_on.src="http://images.med.cornell.edu/headers/navbar/nypcancer/research_on.gif";
	five_off= new Image; five_off.src="http://images.med.cornell.edu/headers/navbar/nypcancer/research_off.gif";
	five_active= new Image; five_active.src="http://images.med.cornell.edu/headers/navbar/nypcancer/research_on.gif";
	
	six_on= new Image; six_on.src="http://images.med.cornell.edu/headers/navbar/nypcancer/resources_on.gif";
	six_off= new Image; six_off.src="http://images.med.cornell.edu/headers/navbar/nypcancer/resources_off.gif";
	six_active= new Image; six_active.src="http://images.med.cornell.edu/headers/navbar/nypcancer/resources_on.gif";

}

// ::::::::::::::::::::::::::: SECTION II: set values for panos, use absolute paths for all file locations

// flash pano: use this if using different pano for each section

if (active == "" && activeHome == "home") {

	panoLoc = "http://media.med.cornell.edu/panoramas/nypcancer/cancer_homepage.swf";

} else if (active == "one") {

	panoLoc = "http://media.med.cornell.edu/panoramas/nypcancer/abo_us.swf";

} else if (active == "two") {

	panoLoc = "http://media.med.cornell.edu/panoramas/nypcancer/hea_ser.swf";

} else if (active == "three") {

	panoLoc = "http://media.med.cornell.edu/panoramas/nypcancer/can_az.swf";

} else if (active == "four") {

	panoLoc = "http://media.med.cornell.edu/panoramas/nypcancer/can_pre.swf";

} else if (active == "five") {

	panoLoc = "http://media.med.cornell.edu/panoramas/nypcancer/research.swf";

} else if (active == "six") {

	panoLoc = "http://media.med.cornell.edu/panoramas/nypcancer/resources.swf";

} else { //default to this just in case

	panoLoc = "http://media.med.cornell.edu/panoramas/nypcancer/neutral.swf";

}

var inAnimation = "";

// set animation to true or false

if (activeHome == "home") {

	inAnimation = "true";

} else {

	inAnimation = "false";

}

// static pano: use this if using different pano for each section

if (active == "" && activeHome == "home") {

	altPanoLoc = "http://images.med.cornell.edu/panoramas/nypcancer/pano_home.jpg";

} else if (active == "one") {

	altPanoLoc = "http://images.med.cornell.edu/panoramas/nypcancer/pano_" + active + ".jpg";

} else if (active == "two") {

	altPanoLoc = "http://images.med.cornell.edu/panoramas/nypcancer/pano_" + active + ".jpg";

} else if (active == "three") {

	altPanoLoc = "http://images.med.cornell.edu/panoramas/nypcancer/pano_" + active + ".jpg";

} else  if (active == "four") {

	altPanoLoc = "http://images.med.cornell.edu/panoramas/nypcancer/pano_" + active + ".jpg";

} else  if (active == "five") {

	altPanoLoc = "http://images.med.cornell.edu/panoramas/nypcancer/pano_" + active + ".jpg";

} else  if (active == "six") {

	altPanoLoc = "http://images.med.cornell.edu/panoramas/nypcancer/pano_" + active + ".jpg";

} else { //default to this just in case

	altPanoLoc = "http://images.med.cornell.edu/panoramas/nypcancer/pano.jpg";

}

siteURL 			= "http://www.nypcancer.org";

// set xml data for pano flash here
dataLoc = "http://global.med.cornell.edu/panoramas/nypcancer/content.xml";

// set loading value here: wmc or nyp
brand = "nyp";

// setting the array, don't touch
buttonArray = new Array ();

// set absolute paths for all the pano toolbar links [image map for static pano]
buttonArray[0] = new createButtonObject ( 16, "http://www.beryl.net/custom/physref/nyp/PhysSearchCriteria.asp");
buttonArray[1] = new createButtonObject ( 4, "http://www.nyp.org/search/search_advanced.html");
buttonArray[2] = new createButtonObject ( 5, "http://www.nypcancer.org/contact.html?name1=NewYork-Presbyterian/Columbia+and+NewYork-Presbyterian/Weill+Cornell&type1=2Active");
buttonArray[3] = new createButtonObject ( 7, "http://www.nypcancer.org/maps/");

// setting the array, don't touch
additionalMapArray	= new Array ();

// VARIABLES FOR WEB TRENDS
//var gFpcDom=".nyppsychiatry.org";
var gDomain="cds.nypcancer.org";
var gDcsId="dcsbrb4rfk711roghvzx6gsg8_8s1z";

function sectionName() {
	var activeSectionName = "";
	if (active == "one") {
		activeSectionName = "About Us";
	} else if (active == "two") {
		activeSectionName = "Healthcare Services";
	} else if (active == "three") {
		activeSectionName = "Cancer A to Z";
	} else if (active == "four") {
		activeSectionName = "Prevention";
	} else if (active == "five") {
		activeSectionName = "Research and Clinical Trials";
	} else if (active == "six") {
		activeSectionName = "Resources";
	} else if (active == "") {
		if (activeHome == "home") {
			activeSectionName = "Home";
		} else {
			activeSectionName = "Toolbar:Quick Info";
		}
	} 
	return activeSectionName;
}

// ::::::::::::::::::::::::::: SECTION III: set 2nd and 3rd level navigation links here, customize according to section

// needed for 4th level links grey line, don't touch
var num4thLevelLinks = 0;

// load 2nd and 3rd level navigation here
function loadLinks() {

	// setting the array, don't touch
	var navLinks = new Array();
	
	if (active == "one") {
	
		// customize section one, 2nd and 3rd level navigation links here
		navLinks[0] = new LeftLink("Welcome", "http://www.nypcancer.org/welcome.html", "2", "", "");
		navLinks[1] = new LeftLink("The Herbert Irving Comprehensive Cancer Center", "http://www.nypcancer.org/herbert_irving.html", "2", "", "");
		navLinks[2] = new LeftLink("Weill Cornell Cancer Center", "http://www.nypcancer.org/cancer_program.html", "2", "", "");
		navLinks[3] = new LeftLink("Diagnostic Innovations", "http://www.nypcancer.org/diagnostic_innovations.html", "2", "", "");
		navLinks[4] = new LeftLink("Therapeutic Excellence", "http://www.nypcancer.org/thera_excellence.html", "2", "", "");
		
	
	} else if (active == "five") {
	
		// customize section two, 2nd and 3rd level navigation links here
		navLinks[0] = new LeftLink("Basic and Clinical Research", "http://www.nypcancer.org/basic_clinical.html", "2", "", "");
		navLinks[1] = new LeftLink("Clinical Trials", "http://www.nypcancer.org/clinical_trials.html", "2", "", "");
	
	} else if (active == "six") {
	
		// customize section two, 2nd and 3rd level navigation links here
		navLinks[0] = new LeftLink("Screening and Support Programs", "http://www.nypcancer.org/resources.html", "2", "", "");
		navLinks[1] = new LeftLink("Breast Cancer", "http://www.nypcancer.org/breast_cancer.html", "3", "Screening and Support Programs", "");
		navLinks[2] = new LeftLink("Digestive Diseases", "http://www.nypcancer.org/digestive_diseases.html", "3", "Screening and Support Programs", "");
		navLinks[3] = new LeftLink("Gynecological Cancers", "http://www.nypcancer.org/gyn_cancers.html", "3", "Screening and Support Programs", "");
		navLinks[4] = new LeftLink("Lung Cancer", "http://www.nypcancer.org/lung_cancer.html", "3", "Screening and Support Programs", "");
		navLinks[5] = new LeftLink("Skin Cancer", "http://www.nypcancer.org/skin_cancer.html", "3", "Screening and Support Programs", "");
		navLinks[6] = new LeftLink("NewYork-Presbyterian Oncology Newsletters", "http://www.nypcancer.org/oncology_newsletters.html", "2", "", "");
		
	} else if (active == "") {
		
		if (activeTool == "maps") {
	
			// customize section two, 2nd and 3rd level navigation links here
			navLinks[0] = new LeftLink('NewYork-Presbyterian/Columbia', 'http://www.nypcancer.org/maps/cpmc_directions.html', '2', '', '');
			navLinks[1] = new LeftLink('Regional Map', 'http://www.nypcancer.org/maps/cpmc_maps.html', '3', 'NewYork-Presbyterian/Columbia', '');
			navLinks[2] = new LeftLink('Campus Map', 'http://www.nypcancer.org/maps/cpmc_campus.html', '3', 'NewYork-Presbyterian/Columbia', '');
			navLinks[3] = new LeftLink('NewYork-Presbyterian/Weill Cornell', 'http://www.nypcancer.org/maps/wcmc_directions.html', '2', '', '');
			navLinks[4] = new LeftLink('Area Map', 'http://www.nypcancer.org/maps/wcmc_area_map.html', '3', 'NewYork-Presbyterian/Weill Cornell', '');
			navLinks[5] = new LeftLink('Interactive Map', 'http://www.nypcancer.org/maps/wcmc_int_map.html', '3', 'NewYork-Presbyterian/Weill Cornell', '');
	
		} else if (activeTool == "contact") {
	
			// customize section two, 2nd and 3rd level navigation links here
			navLinks[0] = new LeftLink('NewYork-Presbyterian/Columbia and NewYork-Presbyterian/Weill Cornell', 'http://www.nypcancer.org/contact.html', '2', '', '');

		}
	
	}

	// returning the value here, don't touch
	return (navLinks);

}


