WebTrends.prototype.dcsCreateImage=function(dcsSrc){ // check if MooTools is available to use
	if (typeof(MooTools)!="undefined"){
		new Element('img',{'src':dcsSrc, 'alt':''}); // image is requested as soon as Element is created
	} else { // if MooTools is not available use standard webtrends mechanism
		if (document.images){
			this.images[this.index]=new Image();
			this.images[this.index].src=dcsSrc;
			this.index++;
		}
		else{
			document.write('<IMG ALT="" BORDER="0" NAME="DCSIMG" WIDTH="1" HEIGHT="1" SRC="'+dcsSrc+'">');
		}
	}
}

WebTrends.prototype.dcsGetId=function(){
	if (this.enabled&&(document.cookie.indexOf(this.fpc+"=")==-1)&&(document.cookie.indexOf("WTLOPTOUT=")==-1)){
		if (typeof(MooTools)!="undefined"){
			new Element('script', {'type':'text/javascript', 
				'src':'http'+(window.location.protocol.indexOf('https:')==0?'s':'')+ '://'+this.domain+'/'+this.dcsid+'/wtid.js'});
		} else { // if MooTools is not available use standard webtrends mechanism
			document.write("<scr"+"ipt type='text/javascript' src='"+"http"+(window.location.protocol.indexOf('https:')==0?'s':'')+"://"+this.domain+"/"+this.dcsid+"/wtid.js"+"'><\/scr"+"ipt>");
		}
	}
}

