var TFT={};TFT.Core={Modules:{oModules:{},addModule:function(B){var A=B.split(" "),C;if(A.length===7){A.shift();}C=A[0].split(",");this.oModules[C[0]]={iVersion:A[1],sTimestamp:A[2]+" "+A[3],sAuthor:A[4]};},isLoaded:function(A){if(typeof this.oModules[A]==="undefined"){return false;}return true;}}};TFT.Core.Modules.addModule("tft.js 22551 2010-07-28 13:02:21Z bkonetzny $");
TFT.Util={Date:{},Form:{},String:{}};TFT.Ext={};TFT.Core.Modules.addModule("console.js 22359 2010-07-22 06:56:50Z bkonetzny $");TFT.Core.Console={bActive:false,bLoggerReady:false,sLogHandler:"",sKeyHandler:"",aKeyFilters:[],aSeverity:[],aMessageBuffer:[],log:function(E,D,B){D=D||"";B=B||"info";var C=true,A;
if(!this.bActive){return false;}else{if(this.aSeverity.join(" ").indexOf(B)===-1){C=false;}if(C&&this.aKeyFilters.length){if(this.sKeyHandler==="include"){A=$.grep(this.aKeyFilters,function(F,G){var H;if(F.indexOf("*")!==-1){H=F.substr(0,F.length-2);return(H===E.substr(0,H.length));}else{return(F===E);
}});if(!A.length){C=false;}}else{if(this.sKeyHandler==="exclude"){A=$.grep(this.aKeyFilters,function(F,G){var H;if(F.indexOf("*")!==-1){H=F.substr(0,F.length-2);return(H===E.substr(0,H.length));}else{return(F===E);}});if(A.length){C=false;}}}}if(C){this.writeLog(E,D,B);}return true;}},writeLog:function(D,B,A){if(this.bLoggerReady){if(this.aMessageBuffer.length){for(var C=0;
C<this.aMessageBuffer.length;C++){this.writeLogHandler(this.aMessageBuffer[C].sKey,this.aMessageBuffer[C].sMessage,this.aMessageBuffer[C].sSeverity);}this.aMessageBuffer=[];}this.writeLogHandler(D,B,A);}else{this.aMessageBuffer.push({sKey:D,sMessage:B,sSeverity:A});}},writeLogHandler:function(C,B,A){if(this.sLogHandler==="console.debug"){if(A==="info"){console.info("["+C+"] "+B);
}else{if(A==="warn"){console.warn("["+C+"] "+B);}else{if(A==="error"){console.error("["+C+"] "+B);}else{console.debug("["+C+"] "+B);}}}}else{if(this.sLogHandler==="div#tft_core_console"){$("div#tft_core_console textarea").val("["+A+"]["+C+"] "+B+"\n"+$("div#tft_core_console textarea").val());}else{if(this.sLogHandler==="alert"){alert("["+A+"]["+C+"] "+B);
}}}},init:function(D,B,E,A,C){B=B||"";E=E||[];A=A||"include";C=C||["info","warn","error"];if(D){if(B!==""){this.sLogHandler=B;}else{if(typeof console!=="undefined"&&typeof console.debug!=="undefined"){this.sLogHandler="console.debug";}else{this.sLogHandler="div#tft_core_console";}}this.aKeyFilters=E;
this.sKeyHandler=A;this.aSeverity=C;if(this.sLogHandler==="div#tft_core_console"){this.createConsoleElement();}else{this.bLoggerReady=true;}this.bActive=true;this.log("TFT.Core.Console.init","Initialised");}else{this.bActive=false;}$(document).ready(function(){TFT.Core.Console.log("TFT.Core.Console.documentReady");
});},toggleLogger:function(A){A=A||true;if(!A){this.log("TFT.Core.Console.toggleLogger","bLoggerReady: "+A);}TFT.Core.Console.bLoggerReady=A;if(A){this.log("TFT.Core.Console.toggleLogger","bLoggerReady: "+A);}},createConsoleElement:function(){$(document).ready(function(){TFT.Core.Console.log("TFT.Core.Console.createConsoleElement","#tft_core_console");
var A="";A+='<div id="tft_core_console" style="z-index: 999; border: 1px solid #000; width: 510px; position: fixed; right: 0px; bottom: 0px; background-color: #ccc; padding: 5px; font-family: Arial; font-size: 10px; color: #000;">';A+='<label for="tft_core_console_log" style="float: left; display: block; font-family: Arial; font-size: 12px; font-weight: bold; color: #000;">TFT.Core.Console:</label>';
A+='<a href="#" style="float: right; font-family: Arial; font-size: 10px; padding-left: 10px; font-weight: normal; color: #000;" onclick="$(\'#tft_core_console\').hide(); return false;">[ close ]</a>';A+="<a href=\"#\" style=\"float: right; font-family: Arial; font-size: 10px; padding-left: 10px; font-weight: normal; color: #000;\" onclick=\"$('#tft_core_console div').toggle(); if($(this).html() == '[ hide ]') { $(this).html('[ show ]'); } else { $(this).html('[ hide ]'); } return false;\">[ hide ]</a>";
A+='<a href="#" style="float: right; font-family: Arial; font-size: 10px; padding-left: 10px; font-weight: normal; color: #000;" onclick="$(\'#tft_core_console textarea\').val(\'\'); return false;">[ clear ]</a>';A+="<a href=\"#\" style=\"float: right; font-family: Arial; font-size: 10px; padding-left: 10px; font-weight: normal; color: #000;\" onclick=\" if($(this).html() == '[ pause ]') { TFT.Core.Console.toggleLogger(false); $(this).html('[ resume ]'); } else { TFT.Core.Console.toggleLogger(true); $(this).html('[ pause ]'); } return false;\">[ pause ]</a>";
A+="<div>";A+='<textarea id="tft_core_console_log" style="clear: both; display: block; width: 500px; height: 100px; font-size: 11px; color: #000;"></textarea>';A+="Mode: "+TFT.Core.Console.sKeyHandler+" | Filter: "+TFT.Core.Console.aKeyFilters;A+="</div>";A+="</div>";$("body").append(A);TFT.Core.Console.bLoggerReady=true;
});}};TFT.Core.Modules.addModule("statistics.js 22366 2010-07-22 07:22:09Z bkonetzny $");TFT.Core.Statistics={Handler:{},bInitialised:false,aActiveHandler:[],oProperties:{},oPropertiesDefaults:{},oPropertiesProvided:{},init:function(A){TFT.Core.Console.log("TFT.Core.Statistics.init","aActiveHandler: "+A);
var B=this;$.each(A,function(C,D){if(typeof B.Handler[D]!=="undefined"){if(typeof B.Handler[D].count!=="undefined"){if(typeof B.Handler[D].init!=="undefined"){B.Handler[D].init();}B.Handler[D].iCount=0;B.aActiveHandler.push(D);}else{TFT.Core.Console.log("TFT.Core.Statistics.init",'Function count() not implemented by handler "'+D+'". Handler will be disabled.',"error");
}}else{TFT.Core.Console.log("TFT.Core.Statistics.init",'Handler "'+D+'" could not be initialized. Please make sure this handler is loaded. Handler will be disabled.',"error");}});this.bInitialised=true;},count:function(A){if(this.bInitialised){A=A||this.aActiveHandler;var B=this;TFT.Core.Console.log("TFT.Core.Statistics.count","aHandlers: "+A);
this.prepareProperties(A);$.each(A,function(C,D){B.Handler[D].count(B.oProperties[D]);B.Handler[D].iCount++;});this.reset(A);}},set:function(A,B){if(this.bInitialised){TFT.Core.Console.log("TFT.Core.Statistics.set","sHandler: "+A);this.reset([A]);this.oPropertiesProvided[A]=B;}},get:function(A,D,F,C){if(this.bInitialised){D=D||"";
F=F||"object";C=C||false;TFT.Core.Console.log("TFT.Core.Statistics.get","sHandler: "+A+" | sProperty: "+D+" | sType: "+F+" | bUseHandler: "+C);var B={},E;if(!C){$.extend(B,this.oPropertiesDefaults[A]);$.extend(B,this.oPropertiesProvided[A]);if(D===""){if(F==="array"){E=[];$.each(B,function(G,H){E.push([G,H]);
});}else{E=B;}}else{E="";if(typeof B[D]!=="undefined"){E=B[D];}}}else{if(typeof this.Handler[A].get!=="undefined"){B=this.Handler[A].get(D);if(F==="array"){E=[];$.each(B,function(G,H){E.push([G,H]);});}else{E=B;}}else{TFT.Core.Console.log("TFT.Core.Statistics.get",'Function get() not implemented by handler "'+A+'".',"error");
}}return E;}},setDefaults:function(A,B){if(this.bInitialised){TFT.Core.Console.log("TFT.Core.Statistics.setDefaults","sHandler: "+A);this.oPropertiesDefaults[A]=B;}},getDefaults:function(A){if(this.bInitialised){TFT.Core.Console.log("TFT.Core.Statistics.getDefaults","sHandler: "+A);return this.oPropertiesDefaults[A];
}else{return{};}},reset:function(A){if(this.bInitialised){A=A||this.aActiveHandler;TFT.Core.Console.log("TFT.Core.Statistics.reset","aHandlers: "+A);var B=this;$.each(A,function(C,D){if(typeof B.Handler[D].reset!=="undefined"){B.Handler[D].reset(B.oProperties[D]);}B.oPropertiesProvided[D]={};B.oProperties[D]={};
});}},prepareProperties:function(A){if(this.bInitialised){A=A||this.aActiveHandler;var B=this;$.each(this.oPropertiesDefaults,function(C,D){if(typeof B.oProperties[C]==="undefined"){B.oProperties[C]={};}$.extend(B.oProperties[C],D);});$.each(this.oPropertiesProvided,function(C,D){if(typeof B.oProperties[C]==="undefined"){B.oProperties[C]={};
}$.extend(B.oProperties[C],D);});$.each(A,function(C,D){if(typeof B.Handler[D].set!=="undefined"){B.oProperties[D]=B.oProperties[D]||{};B.Handler[D].set(B.oProperties[D]);}});}}};TFT.Core.Modules.addModule("googleanalytics.js 22385 2010-07-22 11:15:14Z bkonetzny $");TFT.Core.Statistics.Handler.GoogleAnalytics={init:function(){TFT.Core.Console.log("TFT.Core.Statistics.Handler.GoogleAnalytics.init");
window._gaq=window._gaq||[];(function(){var B=document.createElement("script"),A;B.type="text/javascript";B.async=true;B.src=("https:"===document.location.protocol?"https://ssl":"http://www")+".google-analytics.com/ga.js";A=document.getElementsByTagName("script")[0];A.parentNode.insertBefore(B,A);})();
},count:function(A){A.sPagePath=A.sPagePath||"";TFT.Core.Console.log("TFT.Core.Statistics.Handler.GoogleAnalytics.count","sPagePath: "+A.sPagePath);if(A.sPagePath!==""){window._gaq.push(["_trackPageview",A.sPagePath]);}else{window._gaq.push(["_trackPageview"]);}},set:function(A){A.anonymizeIp=typeof A.anonymizeIp!=="undefined"?A.anonymizeIp:true;
A.aCommands=A.aCommands||[];TFT.Core.Console.log("TFT.Core.Statistics.Handler.GoogleAnalytics.set","oProperties.account: "+A.account+" | oProperties.anonymizeIp: "+A.anonymizeIp);window._gaq.push(["_setAccount",A.account]);if(A.anonymizeIp){window._gaq.push(["_gat._anonymizeIp"]);}$.each(A.aCommands,function(B,C){window._gaq.push(C);
});}};TFT.Core.Modules.addModule("webtrekk.js 22376 2010-07-22 07:24:24Z bkonetzny $");TFT.Core.Statistics.Handler.Webtrekk={init:function(){TFT.Core.Console.log("TFT.Core.Statistics.Handler.Webtrekk.init");window.webtrekk=window.webtrekk||{};},count:function(A){TFT.Core.Console.log("TFT.Core.Statistics.Handler.Webtrekk.count");
if(this.checkWebtrekkExistence()){window.wt_sendinfo();}},set:function(A){A.contentGroup=A.contentGroup||[null,null,null,null,null,null,null,"de_DE"];A.linkTrack=A.linkTrack||"standard";A.heatmap=A.heatmap||0;A.heatmapRefpoint=A.heatmapRefpoint||"wt_refpoint";A.mediaCode=A.mediaCode||"wt_mc";TFT.Core.Console.log("TFT.Core.Statistics.Handler.Webtrekk.set");
if(this.checkWebtrekkExistence()){$.each(A,function(B,C){window.webtrekk[B]=C;});}},get:function(A){TFT.Core.Console.log("TFT.Core.Statistics.Handler.Webtrekk.get");var B={};if(this.checkWebtrekkExistence()){if(A===""){$.each(window.webtrekk,function(C,D){if(typeof D!=="function"&&typeof D!=="object"){B[C]=D;
}});}else{B="";if(typeof window.webtrekk[A]!=="undefined"){B=window.webtrekk[A];}}}return B;},checkWebtrekkExistence:function(){if(typeof window.wt_sendinfo!=="undefined"){return true;}else{TFT.Core.Console.log("TFT.Core.Statistics.Handler.Webtrekk.checkWebtrekkExistence",'"window.wt_sendinfo" is undefined. Please make sure Webtrekk is included.',"error");
return false;}}};
