
var d=document;var currentPage='home';if(d.location.href.indexOf('https:')!=-1){d.write('<script type="text/javascript" src="https://s.cnn.net/nascar/.element/js/2.0/global_nav.js"></script>');}else if(d.location.href.indexOf('www.nascar.com')==-1){d.write('<script type="text/javascript" src="http://i.cdn.turner.com/nascar/.element/js/2.0/global_nav.js"></script>');}
function cnnHasClass(obj){var result=false;if(obj.getAttributeNode('class')!=null){result=obj.getAttributeNode('class').value;}
return result;}
function cnnSetTableBG(id){var even=false;var evenClass='cnnDefault';var oddClass='cnnGeneric';var args=arguments[1];if(args){oddClass=args;}
var tBody=document.getElementById(id);if(!tBody){return;}
var trs=tBody.getElementsByTagName('tr');for(var i=0;i<trs.length;i++){if(!cnnHasClass(trs[i])&&!trs[i].style.backgroundColor){var tds=trs[i].getElementsByTagName('td');for(var j=0;j<tds.length;j++){var td=tds[j];if(j==9){td.className=even?(evenClass+' cnnLast'):(oddClass+' cnnLast');}else{td.className=even?evenClass:oddClass;}}}
even=!even;}}
function cnnCheckSponsorName(id){if(d.getElementById(id)){var tds=d.getElementById(id).getElementsByTagName('td');for(var i=0;i<tds.length;i++){var content=tds[i].innerHTML;if(content.indexOf('.com')!=-1){var pos=content.indexOf('.com');if(pos>=13){tds[i].innerHTML=content.substr(0,13)+"<br>"+content.substr(13,(content.length-1));}}else if(content.lastIndexOf(' ')>0){if((!(content.match(/href/g)))&&(!(content.match(/img/g)))){var strings=content.split(" ");tds[i].innerHTML='';for(var j=0;j<strings.length;j++){if(strings[j].length>13){strings[j]=(strings[j].substr(0,13)+"-<br>"+strings[j].substr(13,strings[j].length));}
tds[i].innerHTML+=strings[j]+" ";}}}}}}
function getCookies(){var hash=new Array;if(document.cookie!=null){var a=document.cookie.split('; ');for(var i=0;i<a.length;i++){var nv=a[i].split('=');if(nv[1]!=null){hash[nv[0]]=nv[1];}}}
return hash;}
function cnnLaunchVideo(url,tab){var videoUrl=url;var popupWidth='800';var popupHeight='600';var name='video';var suffixRE=/\.?$/;var suffix=suffixRE.exec(videoUrl);if(videoUrl.indexOf('/pr/')!=-1){videoUrl=videoUrl.replace('.html',"_frameset_exclude.html");popupWidth=577;popupHeight=465;name='oldVideo';}
if(suffix!=''){if((videoUrl.indexOf('/2006/')!=-1)&&(videoUrl.indexOf('/pr/video')==-1)){videoUrl='/pr/video'+videoUrl.replace(suffixRE,"_frameset_exclude.html");popupWidth=577;popupHeight=465;name='oldVideo';}else{videoUrl=videoUrl.replace(suffixRE,"/frameset.exclude.html");}}
if((videoUrl.indexOf('/video/')==-1)&&((videoUrl.indexOf('/promos/')==-1)||(videoUrl.indexOf('/multimedia/')==-1))){videoUrl="/video"+videoUrl;}
if(tab){videoUrl+=('?'+tab);}else{videoUrl+=('?MostPopular');}
if((videoUrl.indexOf('/video/')!=-1)&&((videoUrl.indexOf('/frameset.exclude.html')!=-1)||(videoUrl.indexOf('_frameset_exclude.html')!=-1)||(videoUrl.indexOf('/index.html')!=-1)||(videoUrl.charAt(videoUrl.length-1)=='/'))){var popupWindow=window.open(videoUrl,name,'width='+popupWidth+',height='+popupHeight+',scrollbars=no,resizable=yes');popupWindow.focus();}else{top.location.href=videoUrl;}
fc_click(url,'media');}
function LaunchVideo(url){var videoUrl=url;var name='oldVideo';var popupWidth='577';var popupHeight='465';var suffixRE=/\.(((np\.|r1\.)?smil|ram)[^\/]*)?$/;var suffix=suffixRE.exec(videoUrl);if(suffix){if(videoUrl.indexOf('/2007/01/3')!=-1){name='video';popupWidth='800';popupHeight='600';if(videoUrl.indexOf('/video/')==-1){videoUrl='/video'+videoUrl.replace(suffixRE,"/frameset.exclude.html");}else{videoUrl=videoUrl.replace(suffixRE,"/frameset.exclude.html");}}else if(videoUrl.indexOf('nascar247')!=-1){name='247';popupWidth='730';popupHeight='460';videoUrl=videoUrl.replace(suffixRE,"_frameset_exclude.html");if(videoUrl.indexOf('/video')==-1){videoUrl='/video'+videoUrl;}}else if(videoUrl.indexOf('/video')!=-1){videoUrl='/pr'+videoUrl.replace(suffixRE,"_frameset_exclude.html");}else{videoUrl='/pr/video'+videoUrl.replace(suffixRE,"_frameset_exclude.html");}
var popupWindow=window.open(videoUrl,name,'width='+popupWidth+',height='+popupHeight+',scrollbars=no,resizable=yes');popupWindow.focus();}else{top.location.href=videoUrl;}}
function cnnLaunchApp(url){appUrl=htmlApp(url);if(url.indexOf('wc')>-1||url.indexOf('bg')>-1){width='750';height='600';}else if(url=='tps'){width='568';height='547';}else if(url.indexOf('rad')>-1){width='577';height='474';}else if(url.indexOf('pc')>-1){width='790';height='554';}else if(url.indexOf('rv')>-1){width='1000';height='700';}
if(appUrl){window.open(appUrl,url,'width='+width+',height='+height+',toolbar=no,menubar=no,location=no,scrollbars=no,resizable=yes');}}
function htmlApp(param){var htmlUrl='';switch(param){case'rvr':htmlUrl='/pr/races/raceview/index.html?product=raceview';break;case'pcr':htmlUrl='/pr/pitcommand/2.0/cup/race/frameset_race_exclude.html?product=pc';break;case'pcq':htmlUrl='/pr/pitcommand/2.0/cup/qual/frameset_qual_exclude.html?product=pc';break;case'rad':htmlUrl='/pr/races/radio/index.html?product=radio';break;case'tps':htmlUrl='/pr/races/scanner/cup/race/index.html?product=scanner';break;case'wcr':htmlUrl='http://racecast.nascar.com/races/leaderboard/cup/race/frameset_race_exclude.html';break;case'wcq':htmlUrl='http://racecast.nascar.com/races/leaderboard/cup/qual/frameset_qual_exclude.html';break;case'wcp1':htmlUrl='http://racecast.nascar.com/races/leaderboard/cup/practice1/frameset_practice1_exclude.html';break;case'wcp2':htmlUrl='http://racecast.nascar.com/races/leaderboard/cup/practice2/frameset_practice2_exclude.html';break;case'wcp3':htmlUrl='http://racecast.nascar.com/races/leaderboard/cup/practice3/frameset_practice3_exclude.html';break;case'bgr':htmlUrl='http://racecast.nascar.com/races/leaderboard/bg/race/frameset_race_exclude.html';break;case'bgq':htmlUrl='http://racecast.nascar.com/races/leaderboard/bg/qual/frameset_qual_exclude.html';break;}
return htmlUrl;}
function LaunchRacecast(url){cnnLaunchApp(url);}
function CNN_openPopup(url,name,widgets,openerUrl){var host=location.hostname;var popupWin=window.open(url,name,widgets);window.top.name="opener";if(popupWin&&popupWin.opener){if(openerUrl){popupWin.opener.location=openerUrl;popupWin.focus();}}}
function openPopUp(url,name,widgets){CNN_openPopup(url,name,widgets);}
function pollSubPop(url,name,widgets){CNN_openPopup(url,name,widgets);}
function openWindow(url,name,widgets){CNN_openPopup(url,name,widgets);}
function jumpLink(url,name,widgets,openerUrl){CNN_openPopup(url,name,widgets,openerUrl);}
function med_vod(vidlocation)
{CNN_openPopup(vidlocation,'620x460','width=620,height=460,scrollbars=no,resizable=no');}
function closeWindow(){top.close();}
var cnnCSIs=new Array();var cnnUseDelayedCSI=0;var localUserAgent=navigator.userAgent.toLowerCase();if((localUserAgent.indexOf('msie')>-1)&&(localUserAgent.indexOf('mac')>-1)){cnnUseDelayedCSI=1;}
function cnnAddCSI(id,source,args,breakCache)
{if(!args){args='';}
breakCache=(!breakCache&&(source.charAt(0)=='/'))?false:true;if(cnnUseDelayedCSI)
{var newCSI=new Object();newCSI.src=source;newCSI.id=id;newCSI.args=args;newCSI.breakCache=breakCache;cnnCSIs[cnnCSIs.length]=newCSI;}
else
{var today=new Date();var currTime=today.getTime();var iframeArgs=(breakCache)?'&time='+currTime:'';if(args)
{iframeArgs=iframeArgs+'&'+args;}
var iframeHtmlSrc='<iframe src="'+source+'?domId='+id+iframeArgs+'" name="iframe'+id+'" id="iframe'+id+'" width="0" height="0" align="right" style="visibility:hidden"></iframe>';document.write(iframeHtmlSrc);}}
function cnnUpdateCSI(html,id)
{var htmlContainerObj=document.getElementById(id)||document.all[id];if(htmlContainerObj)
{htmlContainerObj.innerHTML=html;}
var htmlContentArea=document.body;if(htmlContentArea)
{var previousTopVal=htmlContentArea.style.top||'0px';htmlContentArea.style.top='1px';htmlContentArea.style.top=previousTopVal;}}
function cnnHandleCSIs()
{if(document.body&&document.body.innerHTML&&cnnUseDelayedCSI)
{var iframeOwner=document.getElementById('csiIframe')||document.all['csiIframe'];var iframeHtmlSrc='';for(var incCounter=0;incCounter<cnnCSIs.length;incCounter++)
{var src=cnnCSIs[incCounter].src;var id=cnnCSIs[incCounter].id;var today=new Date();var breakCache=cnnCSIs[incCounter].breakCache;var currTime=today.getTime();var args=(breakCache)?'&time='+currTime:'';if(cnnCSIs[incCounter].args)
{args=args+'&'+cnnCSIs[incCounter].args;}
iframeHtmlSrc+='<iframe src="'+src+'?domId='+id+args+'" name="iframe'+id+'" id="iframe'+id+'" width="0" height="0" align="right"></iframe>';}
if(iframeOwner)
{iframeOwner.innerHTML=iframeHtmlSrc;}}}
var cnnEnableCL=true;var cnnDocDomain='';if(location.hostname.indexOf('.nascar.com')>0){cnnDocDomain='nascar.com';}
if(location.hostname.indexOf('turner.com')>0){if(document.layers){cnnDocDomain='turner.com:'+location.port;}else{cnnDocDomain='turner.com';}}
if(cnnDocDomain){document.domain=cnnDocDomain;}
function WM_browserAcceptsCookies(){var WM_acceptsCookies=false;if(document.cookie==''){document.cookie='WM_acceptsCookies=yes';if(document.cookie.indexOf('WM_acceptsCookies=yes')!=-1){WM_acceptsCookies=true;}}else{WM_acceptsCookies=true;}
return(WM_acceptsCookies);}
function WM_setCookie(name,value,hours,path,domain,secure){if(WM_browserAcceptsCookies()){var numHours=0;var not_NN2=(navigator&&navigator.appName&&(navigator.appName=='Netscape')&&navigator.appVersion&&(parseInt(navigator.appVersion)==2))?false:true;if(hours&&not_NN2){if((typeof(hours)=='string')&&Date.parse(hours)){numHours=hours;}else if(typeof(hours)=='number'){numHours=(new Date((new Date()).getTime()+hours*3600000)).toGMTString();}}
document.cookie=name+'='+escape(value)+((numHours)?(';expires='+numHours):'')+((path)?';path='+path:'')+((domain)?';domain='+domain:'')+((secure&&(secure==true))?'; secure':'');}}
function WM_readCookie(name){if(document.cookie==''){return false;}else{var firstChar,lastChar;var theBigCookie=document.cookie;firstChar=theBigCookie.indexOf(name);var NN2Hack=firstChar+name.length;if((firstChar!=-1)&&(theBigCookie.charAt(NN2Hack)=='=')){firstChar+=name.length+1;lastChar=theBigCookie.indexOf(';',firstChar);if(lastChar==-1)lastChar=theBigCookie.length;return unescape(theBigCookie.substring(firstChar,lastChar));}else{return false;}}}
function WM_killCookie(name,path,domain){var theValue=WM_readCookie(name);if(theValue){document.cookie=name+'='+theValue+'; expires=Fri, 13-Apr-1970 00:00:00 GMT'+((path)?';path='+path:'')+((domain)?';domain='+domain:'');}}
var VBS_Result=false;function CNN_FlashDetect(){}
CNN_FlashDetect.prototype.maxVersionToDetect=8;CNN_FlashDetect.prototype.minVersionToDetect=3;CNN_FlashDetect.prototype.hasPlugin=(navigator.mimeTypes&&navigator.mimeTypes.length&&navigator.mimeTypes["application/x-shockwave-flash"]&&navigator.mimeTypes["application/x-shockwave-flash"].enabledPlugin);CNN_FlashDetect.prototype.hasActiveX=(window.ActiveXObject||((navigator.userAgent&&(navigator.userAgent.indexOf("MSIE")!=-1))&&(navigator.appVersion&&(navigator.appVersion.indexOf("Win")!=-1))));CNN_FlashDetect.prototype.getVersion=function(){var versionNum=0;if(this.hasPlugin){if(navigator.plugins&&navigator.plugins.length&&navigator.plugins["Shockwave Flash"]){var words=navigator.plugins["Shockwave Flash"].description.split(" ");for(var i=0;i<words.length;++i){if(isNaN(parseInt(words[i])))
continue;versionNum=words[i];}}}else if(this.hasActiveX){VBS_Result=false;for(var j=this.maxVersionToDetect;j>=this.minVersionToDetect&&!VBS_Result;versionNum=j--){execScript('on error resume next: VBS_Result = IsObject( CreateObject( "ShockwaveFlash.ShockwaveFlash.'+j+'" ) )','VBScript');}}
return(versionNum);}
CNN_FlashDetect.prototype.detectVersion=function(num){var isVersionSupported=false;if(!isNaN(num)){isVersionSupported=(this.getVersion()>=parseInt(num));}
return(isVersionSupported);}
function CNN_FlashObject(p_name,p_src,p_width,p_height,p_parameters,p_flashVars){this.m_name=p_name;this.m_src=p_src;this.m_width=p_width;this.m_height=p_height;this.m_flashVars=p_flashVars;if(p_parameters)
{this.setParams(p_parameters);}}
CNN_FlashObject.prototype.m_name='';CNN_FlashObject.prototype.m_src='';CNN_FlashObject.prototype.m_width='';CNN_FlashObject.prototype.m_height='';CNN_FlashObject.prototype.m_flashVars='';CNN_FlashObject.prototype.m_params={menu:"false",quality:"high",wmode:"transparent"};CNN_FlashObject.prototype.setParam=function(p_name,p_value){this.m_params[p_name.toLowerCase()]=p_value;}
CNN_FlashObject.prototype.setParams=function(p_paramHash){if(typeof p_paramHash=="object"){for(var param in p_paramHash){if(p_paramHash[param]){this.setParam(param,p_paramHash[param]);}}}}
CNN_FlashObject.prototype.getParam=function(p_name){return(this.m_params[p_name.toLowerCase()]);}
CNN_FlashObject.prototype.getParams=function(){return(this.m_params);}
CNN_FlashObject.prototype.getFlashVarsString=function(){var flashVarsString='';if(typeof this.m_flashVars=="string"){flashVarsString=this.m_flashVars;}else if(typeof this.m_flashVars=="object"){for(var flashVar in this.m_flashVars){if(flashVarsString!=''){flashVarsString+="&";}
flashVarsString+=flashVar+"="+escape(this.m_flashVars[flashVar]);}}
return(flashVarsString);}
CNN_FlashObject.prototype.getAttributeString=function(p_attr,p_value){return(p_value?' '+p_attr+'="'+p_value+'"':'');}
CNN_FlashObject.prototype.getParamTag=function(p_name,p_value){return(p_value?'<param name="'+p_name+'" value="'+p_value+'">':'');}
CNN_FlashObject.prototype.getHtml=function(){var htmlString='';var flashUrl='http://www.macromedia.com/go/getflashplayer';htmlString+='<object type="application/x-shockwave-flash" \
     classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"';htmlString+=this.getAttributeString('pluginspage',flashUrl);htmlString+=this.getAttributeString('id',this.m_name);htmlString+=this.getAttributeString('data',this.m_src);htmlString+=this.getAttributeString('width',this.m_width);htmlString+=this.getAttributeString('height',this.m_height);htmlString+='>';htmlString+=this.getParamTag('movie',this.m_src);for(var oParam in this.getParams()){htmlString+=this.getParamTag(oParam,this.getParam(oParam));}
htmlString+=this.getParamTag('flashVars',this.getFlashVarsString());htmlString+='<embed type="application/x-shockwave-flash"';htmlString+=this.getAttributeString('pluginspage',flashUrl);htmlString+=this.getAttributeString('name',this.m_name);htmlString+=this.getAttributeString('src',this.m_src);htmlString+=this.getAttributeString('width',this.m_width);htmlString+=this.getAttributeString('height',this.m_height);for(var eParam in this.getParams()){htmlString+=this.getAttributeString(eParam,this.getParam(eParam));}
htmlString+=this.getAttributeString('flashVars',this.getFlashVarsString());htmlString+='>';htmlString+='<\/embed>';htmlString+='<\/object>';return(htmlString);}
CNN_FlashObject.prototype.writeHtml=function(){document.write(this.getHtml());}
function TPVidModuleUI(sFeed,sNameID)
{this.m_feed=sFeed;this.STATIC_IMAGE_PATH="http://i.cdn.turner.com/nascar/.e/img/1.1/sect/video/noflash_image.gif";this.NAME=sNameID;this.VERSION=1;this.SWF_PATH="http://i.cnn.net/nascar/.element/swf/2.1/sect/home/tp_vidmodule.swf";}
TPVidModuleUI.prototype.logSession=function()
{document.cookie=this.NAME+"=exists; path=/;";}
TPVidModuleUI.prototype.doesSessionExist=function()
{return(document.cookie.indexOf(this.NAME+"=exists")!=-1);}
TPVidModuleUI.prototype.getSWFPlayerVersion=function()
{var version;return version;}
TPVidModuleUI.prototype.isAolBrowser=function()
{return(navigator.userAgent.toLowerCase().indexOf("aol")!=-1);}
TPVidModuleUI.prototype.getSWFParams=function(sFilePath,fVersion)
{var s="";s+='<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"';s+='codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0" ';s+='width="231" height="173" id="'+this.NAME+'">';s+='<param name="movie" value="'+sFilePath+'?NASCAR_version='+fVersion+'">';s+='<param name="quality" value="high">';s+='<param name="menu" value="true">';s+='<param name="FlashVars" value="NASCAR_feed='+this.m_feed+'&NASCAR_sessionExists='+(this.doesSessionExist()?"true":"false")+'">';s+='<param name="bgcolor" value="#000000">';s+='<embed src="'+sFilePath+'?NASCAR_version='+fVersion+'" quality="high" menu="false" name="'+this.NAME+'" swLiveConnect="true"';s+='bgcolor="#000000" width="231" height="173" type="application/x-shockwave-flash" ';s+='FlashVars="NASCAR_feed='+this.m_feed+'&NASCAR_sessionExists='+(this.doesSessionExist()?"true":"false")+'" ';s+='pluginspage="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash">'
s+='</embed></object>';return s;}
TPVidModuleUI.prototype.getControl=function(){var control;if(navigator.appName.indexOf("Microsoft")!=-1)
{control=window[this.NAME];}
else
{control=document[this.NAME];}
return control;}
TPVidModuleUI.prototype.setSoundEnabled=function(bIsSoundEnabled){this.getControl().SetVariable("NASCAR_isSoundOn",(bIsSoundEnabled)?"true":"false");}
TPVidModuleUI.prototype.getImageParams=function(){var s='<a href="http://www.macromedia.com/go/getflashplayer" target="new"><img src="'+this.STATIC_IMAGE_PATH+'" width="196" height="199" border="0" alt=""><\/a>';return s;}
TPVidModuleUI.prototype.embed=function(){var embedCode;if((!this.isAolBrowser()&&getFlashVersion()>=6)||(this.isAolBrowser()&&getFlashVersion()>6))
{embedCode=this.getSWFParams(this.SWF_PATH,this.VERSION);}else{embedCode=this.getImageParams();}
document.write(embedCode);this.logSession();}
var flashVersion=0;function getFlashVersion(){var agent=navigator.userAgent.toLowerCase();if(agent.indexOf("mozilla/3")!=-1&&agent.indexOf("msie")==-1){flashVersion=0;}
if(navigator.plugins!=null&&navigator.plugins.length>0){var flashPlugin=navigator.plugins['Shockwave Flash'];if(typeof flashPlugin=='object'){if(flashPlugin.description.indexOf('9.')!=-1)flashVersion=9;else if(flashPlugin.description.indexOf('8.')!=-1)flashVersion=8;else if(flashPlugin.description.indexOf('7.')!=-1)flashVersion=7;else if(flashPlugin.description.indexOf('6.')!=-1)flashVersion=6;else if(flashPlugin.description.indexOf('5.')!=-1)flashVersion=5;else if(flashPlugin.description.indexOf('4.')!=-1)flashVersion=4;else if(flashPlugin.description.indexOf('3.')!=-1)flashVersion=3;}}
else if(agent.indexOf("msie")!=-1&&parseInt(navigator.appVersion)>=4&&agent.indexOf("win")!=-1&&agent.indexOf("16bit")==-1){document.write('<scr'+'ipt language="VBScript"\> \n');document.write('on error resume next \n');document.write('dim obFlash \n');document.write('set obFlash = CreateObject("ShockwaveFlash.ShockwaveFlash.7") \n');document.write('if IsObject(obFlash) then \n');document.write('flashVersion = 7 \n');document.write('else set obFlash = CreateObject("ShockwaveFlash.ShockwaveFlash.6") end if \n');document.write('if flashVersion < 7 and IsObject(obFlash) then \n');document.write('flashVersion = 6 \n');document.write('else set obFlash = CreateObject("ShockwaveFlash.ShockwaveFlash.5") end if \n');document.write('if flashVersion < 6 and IsObject(obFlash) then \n');document.write('flashVersion = 5 \n');document.write('else set obFlash = CreateObject("ShockwaveFlash.ShockwaveFlash.4") end if \n');document.write('if flashVersion < 5 and IsObject(obFlash) then \n');document.write('flashVersion = 4 \n');document.write('else set obFlash = CreateObject("ShockwaveFlash.ShockwaveFlash.3") end if \n');document.write('if flashVersion < 4 and IsObject(obFlash) then \n');document.write('flashVersion = 3 \n');document.write('end if');document.write('</scr'+'ipt\> \n');}
else if(agent.indexOf("webtv/2.5")!=-1)flashVersion=3;else if(agent.indexOf("webtv")!=-1)flashVersion=2;else{flashVersion=flashVersion_DONTKNOW;}
return flashVersion;}
var stories=new Array('cnnT1Story1','cnnT1Story2','cnnT1Story3','cnnT1Story4');var rotate=null;var r=1;function cnnRotateT1(){cnnShowT1(r);if(r<4){rotate=setTimeout('cnnRotateT1(r)',7000);}else if(r=4){rotate=setTimeout('cnnShowT1(1)',7000);}
r++;}
function cnnShowT1(n){for(i=0;i<stories.length;i++){if(d.getElementById(stories[i])){d.getElementById(stories[i]).style.display=(('cnnT1Story'+n)==stories[i])?'block':'none';}}
var thumbs=d.getElementById('cnnT1Thumbs').getElementsByTagName('a');for(j=0;j<thumbs.length;j++){thumbs[j].className=((j+1)==n)?'cnnSelected':'';}}
var d=document;var subnavArray=['cnnSubnav_home','cnnSubnav_news','cnnSubnav_video','cnnSubnav_races','cnnSubnav_comm','cnnSubnav_store','cnnSubnav_trackpass'];function cnnBuildNav(){var host='';var imgHost='http://i.cdn.turner.com';if((location.hostname.indexOf('nascar.com')==-1)||((location.hostname.indexOf('.nascar.com')!=-1)&&(location.hostname.indexOf('www.nascar.com')==-1))){host='http://www.nascar.com';}
if(d.location.href.indexOf('https:')!=-1){imgHost='https://s.cnn.net';}
d.writeln('<div id="cnnHeader">');d.writeln('<form name="ncar_search" method="get" action="http://search.nascar.com/pages/search/advanced.jsp" id="cnnSearch">');d.writeln('<input name="Coll" value="nascar_xml" type="hidden">');d.writeln('<input name="QuerySubmit" value="true" type="hidden">');d.writeln('<input name="Page" value="1" type="hidden">');d.writeln('<input name="LastQuery" value="" type="hidden">');d.writeln('<input name="keywords" type="hidden"><input type="hidden" name="source" value="NSS">');d.writeln('<input type="text" class="cnnInput" name="QueryText">');d.writeln('<input type="image" src="'+imgHost+'/nascar/.e/img/2.0/global/util/pixel.gif" class="cnnSubmit" alt="GO >">');d.writeln('</form>');d.writeln('<ul id="cnnTopNav">');d.writeln('<li><a href="'+host+'/" id="cnnLogo"></a></li>');d.writeln('<li onmouseover="cnnShowSubnav(\'0\')" onmouseout="cnnStartTimeout()"><a href="'+host+'/" id="cnnHome"></a>');d.writeln('<ul id="cnnSubnav_home">');d.writeln('<li><a href="'+host+'/drivers/list/cup/dps/">Drivers</a></li>');d.writeln('<li><a href="'+host+'/kyn/nbtn/">Statistics</a></li>');d.writeln('<li><a href="'+host+'/promos/redirects/races/standings.exclude.html">Standings</a></li>');d.writeln('<li><a href="'+host+'/promos/redirects/races/schedule.exclude.html">Schedule</a></li>');d.writeln('<li><a href="'+host+'/kyn/">NASCAR 101</a></li>');d.writeln('<li><a href="'+host+'/multimedia/photo_gallery/">Photos</a></li>');d.writeln('<li><a href="'+host+'/races/tracks/">Tracks</a></li>');d.writeln('<li><a href="'+host+'/races/tickets/cup/">Tickets</a></li>');d.writeln('<li><a href="http://fantasy.nascar.com/">Fantasy</a></li>');d.writeln('<li><a href="'+host+'/games/">Games</a></li>');d.writeln('<li><a href="'+host+'/games/sweeps/">Sweepstakes</a></li>');d.writeln('</ul>');d.writeln('</li>');d.writeln('<li onmouseover="cnnShowSubnav(\'1\')" onmouseout="cnnStartTimeout()"><a href="'+host+'/news/" id="cnnNews"></a>');d.writeln('<ul id="cnnSubnav_news">');d.writeln('<li><a href="'+host+'/drivers/list/cup/dps/">Drivers</a></li>');d.writeln('<li><a href="'+host+'/promos/redirects/races/results.exclude.html">Results</a></li>');d.writeln('<li><a href="'+host+'/promos/redirects/races/standings.exclude.html">Standings</a></li>');d.writeln('<li><a href="'+host+'/promos/redirects/races/schedule.exclude.html">Schedule</a></li>');d.writeln('<li><a href="'+host+'/kyn/nbtn/">Statistics</a></li>');d.writeln('<li><a href="'+host+'/news/business/">Business</a></li>');d.writeln('<li><a href="'+host+'/news/opinion/">Opinion</a></li>');d.writeln('<li><a href="'+host+'/kyn/">NASCAR 101</a></li>');d.writeln('<li><a href="'+host+'/news/newsletter/">Newsletter</a></li>');d.writeln('<li><a href="'+host+'/services/rss/">RSS</a></li>');d.writeln('<li><a href="'+host+'/news/alerts/">Alerts</a></li>');d.writeln('<li><a href="'+host+'/promos/redirects/comm/collectibles.exclude.html">Collectibles</a></li>');d.writeln('</ul>');d.writeln('</li>');d.writeln('<li onmouseover="cnnShowSubnav(\'2\')" onmouseout="cnnStartTimeout()"><a href="'+host+'/multimedia/" id="cnnVideo"></a>');d.writeln('<ul id="cnnSubnav_video">');d.writeln('<li><a href="'+host+'/multimedia/drivers/">Driver Clips</a></li>');d.writeln('<li><a href="'+host+'/multimedia/cup/">Race Clips</a></li>');d.writeln('<li><a href="'+host+'/promos/redirects/multimedia/race_rewind.exclude.html">Race Rewind</a></li>');d.writeln('<li><a href="'+host+'/promos/redirects/multimedia/race_chatter.exclude.html">In-car audio</a></li>');d.writeln('<li><a href="'+host+'/promos/redirects/multimedia/jd.exclude.html">Post-race show</a></li>');d.writeln('<li><a href="'+host+'/promos/tnt/">NASCAR ON TNT</a></li>');d.writeln('</ul>');d.writeln('</li>');d.writeln('<li onmouseover="cnnShowSubnav(\'3\')" onmouseout="cnnStartTimeout()"><a href="'+host+'/races/cup/" id="cnnRaces"></a>');d.writeln('<ul id="cnnSubnav_races">');d.writeln('<li><a href="'+host+'/news/">News</a></li>');d.writeln('<li><a href="'+host+'/promos/redirects/races/results.exclude.html">Results</a></li>');d.writeln('<li><a href="'+host+'/races/tracks/">Tracks</a></li>');d.writeln('<li><a href="'+host+'/races/tickets/cup/">Tickets</a></li>');d.writeln('<li><a href="'+host+'/travel/">Travel</a></li>');d.writeln('<li><a href="'+host+'/comm/tailgating/">Tailgating</a></li>');d.writeln('<li><a href="'+host+'/promos/redirects/races/standings.exclude.html">Standings</a></li>');d.writeln('<li><a href="'+host+'/promos/redirects/races/schedule.exclude.html">Schedule</a></li>');d.writeln('<li><a href="'+host+'/multimedia/">Video</a></li>');d.writeln('<li><a href="'+host+'/promos/redirects/races/results.exclude.html">Past Races</a></li>');d.writeln('<li><a href="'+host+'/promos/tnt/">NASCAR ON TNT</a></li>');d.writeln('</ul>');d.writeln('</li>');var csSubnav=getCookies();var user=csSubnav["displayname"];var uname='';if(user){uname=user;}
d.writeln('<li onmouseover="cnnShowSubnav(\'4\')" onmouseout="cnnStartTimeout()"><a href="http://community.nascar.com/" id="cnnComm"></a>');d.writeln('<ul id="cnnSubnav_comm">');d.writeln('<li><a href="http://community.nascar.com/'+uname+'">My Profile</a></li>');d.writeln('<li><a href="http://community.nascar.com/members">Members</a></li>');d.writeln('<li><a href="http://community.nascar.com/crews">Crews</a></li>');d.writeln('<li><a href="http://community.nascar.com/blogs">Blogs</a></li>');d.writeln('<li><a href="http://community.nascar.com/photos">Photos</a></li>');d.writeln('<li><a href="http://community.nascar.com/videos">Videos</a></li>');d.writeln('<li><a href="'+host+'/promos/redirects/onmc/global_nav.exclude.html">NASCAR Members Club</a></li>');d.writeln('<li><a href="'+host+'/promos/redirects/comm/chat.exclude.html">Chat</a></li>');d.writeln('<li><a href="'+host+'/forums">Forums</a></li>');d.writeln('<li><a href="'+host+'/services/widgets">Widgets</a></li>');d.writeln('</ul>');d.writeln('</li>');d.writeln('<li onmouseover="cnnShowSubnav(\'5\')" onmouseout="cnnStartTimeout()"><a href="http://store.nascar.com" id="cnnStore"></a>');d.writeln('<ul id="cnnSubnav_store">');d.writeln('<li><a href="http://store.nascar.com/entry.point?entry=2056462&source=nascar_dhtml:diecast:03_13_07">Die-Cast</a></li>');d.writeln('<li><a href="http://store.nascar.com/entry.point?entry=1251516&source=nascar_dhtml:outerwear:03_13_07">Outerwear</a></li>');d.writeln('<li><a href="http://store.nascar.com/entry.point?entry=1251496&source=nascar_dhtml:hats:03_13_07">Headwear</a></li>');d.writeln('<li><a href="http://store.nascar.com/entry.point?entry=1251497&source=nascar_dhtml:tees:03_13_07">Tees</a></li>');d.writeln('<li><a href="http://store.nascar.com/entry.point?entry=2056660&source=nascar_dhtml:womens:03_13_07">Womens</a></li>');d.writeln('<li><a href="http://store.nascar.com/entry.point?entry=2056464&source=nascar_dhtml:tailgating:03_13_07">Tailgating</a></li>');d.writeln('<li><a href="http://store.nascar.com/entry.point?entry=2056463&source=nascar_dhtml:homeoffice:03_13_07">Home and Office</a></li>');d.writeln('<li><a href="http://store.nascar.com/emailSignup/index.jsp?partner=header">Sign Up &amp; Save 15%</a></li>');d.writeln('</ul>');d.writeln('</li>');d.writeln('<li onmouseover="cnnShowSubnav(\'6\')" onmouseout="cnnStartTimeout()"><a href="'+host+'/trackpass/" id="cnnTrackPass"></a>');d.writeln('<ul id="cnnSubnav_trackpass">');d.writeln('<li><a href="'+host+'/trackpass/about/scanner/">Scanner</a></li>');d.writeln('<li><a href="'+host+'/trackpass/about/pitcommand/">PitCommand</a></li>');d.writeln('<li><a href="'+host+'/trackpass/about/raceview/">RaceView</a></li>');d.writeln('<li><a href="'+host+'/trackpass/about/">Learn More</a></li>');d.writeln('<li><a href="https://secure.audience.nascar.com/services/nascar/pitpass/login.do?requestedpage=http://www.nascar.com/trackpass/">Login</a></li>');d.writeln('<li><a href="https://account.nascar.com/storefront/memberservices/manageSub.do">Manage My TrackPass</a></li>');d.writeln('<li><a href="'+host+'/guides/customer_service/trackpass/">Help</a></li>');d.writeln('</ul>');d.writeln('</li>');d.writeln('</ul>');d.writeln('<div id="cnnEnEsp"><a href="'+host+'/espanol/">En Espa&ntilde;ol</a></div>');d.writeln('</div>');}
function cnnHideSubnav(){for(var i=0;i<subnavArray.length;i++){d.getElementById(subnavArray[i]).style.display='none';}}
function cnnShowSubnav(x){if(hide!=null){clearTimeout(hide);}
if(d.getElementById(subnavArray[x])){cnnHideSubnav();d.getElementById(subnavArray[x]).style.display='block';}}
function cnnRevertSubnav(){var defaultSubnav='cnnSubnav_'+currentPage;if(!Array.prototype.indexOf){for(var i=0;i<subnavArray.length;i++){if(subnavArray[i]==defaultSubnav){cnnShowSubnav(i);}}}else{var position=subnavArray.indexOf(defaultSubnav);if(position!=-1){cnnShowSubnav(position);}else{cnnHideSubnav();}}}
var hide=null;function cnnStartTimeout(){hide=setTimeout('cnnRevertSubnav()',7000);}
if(window.attachEvent){document.attachEvent('onclick',cnnDefectorCheck);}else{window.addEventListener('click',cnnDefectorCheck,false);}
function cnnDefectorCheck(){if((location.hostname.indexOf('nascar.com')!=-1)||((location.hostname.indexOf('.nascar.com')!=-1)&&((location.hostname.indexOf('foundation.nascar.com')==-1)||(location.hostname.indexOf('employment.nascar.com')==-1)||(location.hostname.indexOf('store.nascar.com')==-1)||(location.hostname.indexOf('fantasy.nascar.com')==-1)||(location.hostname.indexOf('forums.nascar.com')==-1)))&&(auth)){cnnPopUpAd();}}
AdCookieName='defector';AdCookieExpire=1;AdName='defector';AdLimit=1;AdSessionTime=1440;AdURL='http://www.nascar.com/promos/referfriend/popunder/index.html';AdWidth=1;AdHeight=1;AdDomain="";var t=new Date();var year=t.getFullYear();var month=t.getMonth()+1;var day=t.getDate();var hour=t.getHours();var min=t.getMinutes();var sec=t.getSeconds();AdSessionID=year+'.'+month+'.'+day+'.'+hour+'.'+min+'.'+sec;AdSessionMin=0;with(navigator){var aN=appName,uA=userAgent,aV=parseInt(appVersion);}
ie=(uA.indexOf("MSIE")>0||aN.indexOf("Microsoft")==0);mac=(uA.indexOf("Mac")>0);if(!mac&&ie&&aV<4)
{var msieStart=navigator.appVersion.indexOf("MSIE");var msieVer=navigator.appVersion.substring(msieStart+5,navigator.appVersion.length);aV=parseInt(msieVer);}
function findDomain(){var docURL="";var docDomain="";if(!mac&&ie&&aV<4){docURL=window.document.location;}
else if(mac&&ie&&aV<4){docURL=window.document.location.href;}
else{docURL=window.document.URL;}
if(docURL!=null&&docURL!="")
if(docURL.indexOf("http://")!=-1)
{var endDomain=docURL.indexOf("/",7);var docDomain="";docDomain=docURL.substring(7,endDomain);var firstDot=docDomain.lastIndexOf(".");if(firstDot!=-1){var secondDot=docDomain.lastIndexOf(".",firstDot-1);if(secondDot!=-1)
AdDomain=docDomain.substring(secondDot,docDomain.length);}}}
function setCNNCookieDate(){var cookieDate=new Date();var year;var month;var day;if(!(mac&&ie)){month=cookieDate.getMonth();year=cookieDate.getYear();day=cookieDate.getDate();if(year<2000)year+=1900;}
else{year=AdSessionID.substring(0,4);var dotpos=AdSessionID.indexOf(".",5);month=AdSessionID.substring(5,dotpos);var dotpos2=AdSessionID.indexOf(".",dotpos+1);day=AdSessionID.substring(dotpos+1,dotpos2);month--;}
month+=AdCookieExpire;while(month>11){month=month-12;year++;}
cookieDate.setYear(year);cookieDate.setMonth(month);cookieDate.setDate(day);var CNNcookieDate=cookieDate.toGMTString();return CNNcookieDate;}
function CNNCookie(){this.sh=0;this.id=0;}
function decodeCNNCookie(cookieValue){var searchString=AdName+"(";var start=cookieValue.indexOf(searchString);var cnnCookie=new CNNCookie();if(start==-1)cnnCookie.restString=(cookieValue);else{var extractStart=start+searchString.length;var end=cookieValue.indexOf(")",extractStart);if(end==-1)end=cookieValue.length;var cookieExtract=cookieValue.substring(extractStart,end);cnnCookie.restString=cookieValue.substring(0,start);cnnCookie.restString+=cookieValue.substring(end+1,cookieValue.length);start=0;while(start<cookieExtract.length)
{end=cookieExtract.indexOf(':',start);if(end==-1)break;var attributeName=cookieExtract.substring(start,end);start=end+1;end=cookieExtract.indexOf('&',start);if(end==-1)end=cookieExtract.length;var attributeVal=unescape(cookieExtract.substring(start,end));start=end+1;cnnCookie[attributeName]=attributeVal;}}
return cnnCookie;}
function getCNNCookie(){var cnnCookie=null;if(document.cookie.length>0){var search=AdCookieName+"=";var offset=document.cookie.indexOf(search);if(offset!=-1){offset+=search.length;end=document.cookie.indexOf(";",offset);if(end==-1)end=document.cookie.length;cnnCookie=decodeCNNCookie(document.cookie.substring(offset,end));}}
return cnnCookie;}
function storeCNNCookie(cnnCookie)
{if(cnnCookie==null)return;var cookieVal="";for(var prop in cnnCookie)
{if(prop!="restString"){if(cookieVal!="")cookieVal+='&';cookieVal+=prop+':'+escape(cnnCookie[prop]);}}
var cookieString=AdCookieName+"=";cookieString+=AdName+"("+cookieVal+")";if(cnnCookie.restString!=null)cookieString+=cnnCookie.restString;cookieString+='; expires='+setCNNCookieDate();if(AdDomain!="")cookieString+='; domain='+AdDomain;cookieString+='; path=/';document.cookie=cookieString;}
function setCNNCookie()
{var newcnnCookie=new CNNCookie();storeCNNCookie(newcnnCookie);}
function getMinFromStamp(stamp)
{var year=stamp.substring(0,4);var dotpos=stamp.indexOf(".",5);var month=stamp.substring(5,dotpos);var dotpos2=stamp.indexOf(".",dotpos+1);var day=stamp.substring(dotpos+1,dotpos2);dotpos=stamp.indexOf(".",dotpos2+1);var hour=stamp.substring(dotpos2+1,dotpos);dotpos2=stamp.indexOf(".",dotpos+1);var minute=stamp.substring(dotpos+1,dotpos2);var stampDate=new Date(year,parseInt(month)-1,day,hour,minute,0);var minutes=stampDate.getTime()/60000;return minutes;}
function validateCNNCookie(cnnCookie){var returnVal=true;if(cnnCookie.sh>=AdLimit||(((AdSessionTime)+parseInt(cnnCookie.id))>AdSessionMin))
returnVal=false;return(returnVal);}
function updateCNNCookie(cnnCookie){cnnCookie.sh++;cnnCookie.id=AdSessionMin;storeCNNCookie(cnnCookie);}
function cnnPopUpAd()
{if(aV>=3){findDomain();var cnnCookie=getCNNCookie();if(cnnCookie==null){setCNNCookie();cnnCookie=getCNNCookie();if(cnnCookie==null)return;}
AdSessionMin=getMinFromStamp(AdSessionID);if(cnnCookie!=null&&validateCNNCookie(cnnCookie)){open(AdURL,"AdInterstitial","height="+AdHeight+",width="+AdWidth);updateCNNCookie(cnnCookie);}}}