
// catcher
function doNothing() {};


// get base url 
with (this.location) { baseURL = href.substring(0, href.lastIndexOf ("/") + 1) }


// browser and OS detection
var browserOS = navigator.platform;
var webBrowser = navigator.appName;
var browserVer = navigator.appVersion.substring(0,3);


// stylesheet assignment

	if ((browserOS == "Win32") && (webBrowser == "Microsoft Internet Explorer")) {
		styleObj = '<link rel="stylesheet" href=/code/explorer.css type="text/css">';
	} else if ((browserOS == "MacPPC") && (webBrowser == "Microsoft Internet Explorer")) {
		styleObj = '<link rel="stylesheet" href=/code/explorerMAC.css type="text/css">';
	} else if ((browserOS == "Win32") && (webBrowser == "Netscape") && (browserVer.indexOf('5') != -1)) {
		styleObj = '<link rel="stylesheet" href=/code/netscape6PC.css type="text/css">';
	} else if ((browserOS == "Win32") && (webBrowser == "Netscape") && (browserVer.indexOf('4') != -1)) {
		styleObj = '<link rel="stylesheet" href=/code/netscape4PC.css type="text/css">';
	} else if ((browserOS == "MacPPC") && (webBrowser == "Netscape") && (browserVer.indexOf('5') != -1)) {
		styleObj = '<link rel="stylesheet" href=/code/explorer.css type="text/css">';
	} else if ((browserOS == "MacPPC") && (webBrowser == "Netscape") && (browserVer.indexOf('4') != -1)) {
		styleObj = '<link rel="stylesheet" href=/code/netscape4mac.css type="text/css">';
	} else {
		styleObj = '<link rel="stylesheet" href=/code/generic.css type="text/css">';
	}


//For Image Swapping
Nav1on = new Image()
Nav1on.src = "images/media/press_releases_on.gif";

Nav1off = new Image()
Nav1off.src = "images/media/press_releases.gif";

Nav2on = new Image()
Nav2on.src = "images/media/in_the_news_on.gif";

Nav2off = new Image()
Nav2off.src = "images/media/in_the_news.gif";

Nav3on = new Image()
Nav3on.src = "images/media/photography_on.gif";

Nav3off = new Image()
Nav3off.src = "images/media/photography.gif";

Nav4on = new Image()
Nav4on.src = "images/media/speakers_bureau_on.gif";

Nav4off = new Image()
Nav4off.src = "images/media/speakers_bureau.gif";

Nav5on = new Image()
Nav5on.src = "images/media/contact_pr_team_on.gif";

Nav5off = new Image()
Nav5off.src = "images/media/contact_pr_team.gif";

Nav6on = new Image();
Nav6on.src = "/images/nav/findarep_on.gif";

Nav6off = new Image();
Nav6off.src = "/images/nav/findarep_off.gif";



function imgAct(imgNum) {
var thisimagename = "Nav" + imgNum;
    if (document.images) {
    document[thisimagename].src = eval("Nav" + imgNum + "on.src");
    }
}

function imgInact(imgNum) {
var thisimagename = "Nav" + imgNum;
    if (document.images) {
    document[thisimagename].src = eval("Nav" + imgNum + "off.src");
    }
}

function imgActR() {
    if (document.images) {
    document.Nav6.src = eval("Nav6on.src");
    self.status = "find a rep";
    }
}

function imgInactR() {
    if (document.images) {
    document.Nav6.src = eval("Nav6off.src");
    self.status = "";
    }
}



//End for Image Swapping


// global variables 


var num = null;

// image name construction 

imageDir	= "/images/nav/";
offSuffix	= "_off.gif";
onSuffix	= "_on.gif";

var totalMice = 0;	     
var mausArray = new Array();



// create new mausover objects

function mausObj (width, height, name, statusText) {

  this.width		= width;
  this.height		= height;
  this.name			= name;
  this.statusText	= statusText; 
  this.off			= new Image (width, height);
  this.off.src		= imageDir + name + offSuffix;  
  this.on			= new Image (width, height);
  this.on.src		= imageDir + name + onSuffix;  

}

function makeMausObj(width, height, name, statusText) {

   mausArray[totalMice] = new mausObj(width, height, name, statusText);
  
  totalMice++;
  
}


// mouseover

function doMausOver(num) {

	document.images[mausArray[num].name].src = mausArray[num].on.src;
	self.status = mausArray[num].statusText;

}


// mouseout

function doMausOut (num) {

	document.images[mausArray[num].name].src = mausArray[num].off.src;
      
	self.status = "";

}

//my pop up window code

function open_window2(url, target, w, h) {
		newWindow = window.open(url, target,'toolbar=1,location=1,directories=1,status=1,menubar=1,scrollbars=1,left=100, top=100, resizable=1,' + 'width=' + w + ',height=' + h);
	}


function open_windowTheMarket() {
var url="/TheMarket/";
var target="_blank";
var w=733;
var h=633;
		newWindow = window.open(url, target,'toolbar=1,location=1,directories=1,status=1,menubar=1,scrollbars=1,left=100, top=100 resizable=1,' + 'width=' + w + ',height=' + h);
	}
	
function open_windowFindaDealer() {
var url="http://66.110.208.219/wl/find/FindADealer.asp";
var target="_blank";
var w=733;
var h=633;
		newWindow = window.open(url, target,'toolbar=1,location=1,directories=1,status=1,menubar=1,scrollbars=1,left=100, top=100 resizable=1,' + 'width=' + w + ',height=' + h);
	}
//end of my code




// pencilbox popup window code

	function thisIsPop(page, pWidth, pHeight, scrollSet) {
	
		var popWindow = null;
		page = page + ".html";
		
		if (!pWidth) {
			var pWidth = 410;
		}	
		
		if (!pHeight) {
			var pHeight = 400;
		}	

		if (!scrollSet) {
			var scrollSet = 1;
		}

			var displayString = "width=" + pWidth + ",height=" + pHeight + ",scrollbars=" + scrollSet +",resizable";   
			
    		popWindow = window.open(page,'PopWindow',displayString);

				if (popWindow != null) {
					if (popWindow.opener == null) { popWindow.opener = self; }
					popWindow.opener.name = "popDaddy";
				} 		
		
	}



	function topFloat() { 
		if (document.images) {
			parent.focus();					
			setTimeout("topFloat()",1000);
		} else { return; }
 	}


// IFS header rollovers
// rollover image array (width, height, name, statusText)

makeMausObj(60, 47, "topNav-products", "Products");
makeMausObj(50, 47, "topNav-gallery", "Gallery");
makeMausObj(99, 47, "topNav-enduse", "End-Use Segments");
makeMausObj(80, 47, "topNav-sustain", "Sustainability");
makeMausObj(77, 47, "topNav-profile", "Brand Profile");
makeMausObj(102, 47, "topNav-what", "What's Happening");
makeMausObj(96, 47, "topNav-library", "Reference Library");


// IFS footer

// rollover image array (width, height, name, statusText) 

makeMausObj(160, 51, "footerNav-home", "home");
makeMausObj(160, 51, "footerNav-sitemap", "site map");
makeMausObj(160, 16, "themarket", "the market at Interface");
makeMausObj(160, 16, "ourlocations", "our locations");
//makeMausObj(160, 16, "findarep", "find a rep");
makeMausObj(160, 16, "findadealer", "find a dealer");
makeMausObj(160, 16, "contactus", "contact us");

var footerNav;

//footerNav  = '<p>&nbsp;</p>';
footerNav = '<br>';
footerNav += '<img src="/images/nav/footer-ifs_hr.gif" alt="" width="564" height="20" border="0"><br><br>';
footerNav += '<table cellpadding="0" cellspacing="0" border="0" width="564">';
footerNav += '<tr>';
footerNav += '<td><a href="http://www.interfaceflooring.com" onMouseOver="doMausOver(7); return true" onMouseOut="doMausOut(7); return true"><img src="/images/nav/footerNav-home_off.gif"'; 
footerNav += ' alt="home" width="160" height="51" border="0" name="footerNav-home"></a';
footerNav += '><br><a href="http://www.interfaceinc.com/"><img src="/images/nav/interfacelogo.gif" width="160" height="23" border="0"></a><br><img src="/images/nav/shimbtm.gif" width="160" height="6" border="0"></td';
footerNav += '><td><a href="http://www.interfaceflooring.com/sitemap/" onMouseOver="doMausOver(8); return true" onMouseOut="doMausOut(8); return true"><img src="/images/nav/footerNav-sitemap_off.gif"'; 
footerNav += ' alt="site map" width="160" height="51" border="0" name="footerNav-sitemap"></a></td';
footerNav += '><td>';
footerNav += '<a HREF="javascript:open_windowTheMarket()" onMouseOver="doMausOver(9); return true" onMouseOut="doMausOut(9); return true"><img';
footerNav += ' src="/images/nav/themarket_off.gif" alt="the market at Interface" width="160" height="16" border="0" name="themarket"></a><br';
footerNav += '>';
footerNav += '<a href="http://www.interfaceflooring.com/ourlocations.html" onMouseOver="doMausOver(10); return true" onMouseOut="doMausOut(10); return true"><img';
footerNav += ' src="/images/nav/ourlocations_off.gif" alt="our locations" width="160" height="16" border="0" name="ourlocations"></a><br';
footerNav += '>';
footerNav += '<a href="/find_a_rep/repsearch.html" onMouseOver="imgActR(); return true" onMouseOut="imgInactR(); return true"><img';
footerNav += ' src="/images/nav/findarep_off.gif" alt="find a rep" width="160" height="16" border="0" name="Nav6"></a><br';
footerNav += '>';
footerNav += '<a HREF="javascript:open_windowFindaDealer()" onMouseOver="doMausOver(11); return true" onMouseOut="doMausOut(11); return true"><img';
footerNav += ' src="/images/nav/findadealer_off.gif" alt="find a dealer" width="160" height="16" border="0" name="findadealer"></a><br';
footerNav += '>';
footerNav += '<a href="http://www.interfaceflooring.com/contact/" onMouseOver="doMausOver(12); return true" onMouseOut="doMausOut(12); return true"><img';
footerNav += ' src="/images/nav/contactus_off.gif" alt="contact us" width="160" height="16" border="0" name="contactus"></a><br';
footerNav += '>';
footerNav += ' </td>'; 
footerNav += '</tr>';
footerNav += '<tr>';
footerNav += '<td width="188"><img src="/images/spacer.gif" width="188" height="1" alt=""></td';
footerNav += '><td width="188"><img src="/images/spacer.gif" width="188" height="1" alt=""></td';
footerNav += '><td width="188"><img src="/images/spacer.gif" width="188" height="15" alt=""></td>';
footerNav += '</tr>'; 
footerNav += '</table>';






































	
