var now = new Date();
var jvSeed = Math.random() * now.valueOf() * 100000;
jvSeed = jvSeed.toString().substr(0, 15);
var jvPURL = '';
var defaultPath = '';
var BottomInclude = '';
var strInterstitial = '';

function GetAd(TheTile, ThePosition, ThePath, TheKeyword, TheSiteUrl, TheInterstitial, TheWidth, TheHeight) {
    if (ThePath == '') {
        ThePath = defaultPath;
    }
    ThePath = TheSiteUrl + ThePath;
    if((TheWidth=='null' && TheHeight=='null')||(TheWidth=='' && TheHeight=='')){
    	document.write('<SCR'+'IPT type="text/javascript" language="JavaScript1.1" SRC="http://ad.doubleclick.net/adj/'+ThePath+';abr=!webtv;kw='+TheKeyword+';pos='+ThePosition+TheInterstitial+';'+TheTile+'='+ThePosition+';ord='+jvSeed+'?"></SCR'+'IPT>');
	    if ((!document.images && navigator.userAgent.indexOf('Mozilla/2.') >= 0)  || navigator.userAgent.indexOf("WebTV")>= 0) {
	        document.write('<A HREF="http://ad.doubleclick.net/jump/'+ThePath+';kw='+TheKeyword+';pos='+ThePosition+';'+TheTile+'='+ThePosition+';ord='+jvSeed+'?">');
	        document.write('<IMG SRC="http://ad.doubleclick.net/ad/'+ThePath+';kw='+TheKeyword+';pos='+ThePosition+';'+TheTile+'='+ThePosition+';ord='+jvSeed+'?" border="0"></A>');
	    }  
	  }else{
	  	document.write('<SCR'+'IPT type="text/javascript" language="JavaScript1.1" SRC="http://ad.doubleclick.net/adj/'+ThePath+';abr=!webtv;kw='+TheKeyword+';pos='+ThePosition+TheInterstitial+';sz='+TheWidth+'x'+TheHeight+';'+TheTile+'='+ThePosition+';ord='+jvSeed+'?"></SCR'+'IPT>');
			if ((!document.images && navigator.userAgent.indexOf('Mozilla/2.') >= 0)  || navigator.userAgent.indexOf("WebTV")>= 0) {
		  	document.write('<A HREF="http://ad.doubleclick.net/jump/'+ThePath+';kw='+TheKeyword+';pos='+ThePosition+';sz='+TheWidth+'x'+TheHeight +';'+TheTile+'='+ThePosition+';ord='+jvSeed+'?">');
		    document.write('<IMG SRC="http://ad.doubleclick.net/ad/'+ThePath+';kw='+TheKeyword+';pos='+ThePosition+';sz='+TheWidth+'x'+TheHeight +';'+TheTile+'='+ThePosition+';ord='+jvSeed+'?" border="0"></A>');
    	}
	  }
}