84e2f272052d386779f00694399d4dcbbad2def9c0e1f56e7ab16d133c2cef57

Source Code:

!function(a,b,c){"use strict";var d={};d.version="1.2.5",d.get_cookies=function(){for(var a=c.cookie.split(";"),b={},d=0,e=a.length;d<e;d++)a[d]=a[d].replace(/^\s+|\s+$/g,""),b[a[d].split("=")[0]]=a[d].split("=")[1];return b},d.set_cookie=function(a,b,d){var e=new Date;e.setTime(e.getTime()+24*d*60*60*1e3);var f="; expires="+e.toUTCString();c.cookie=a+"="+b+f+"; path=/"},d.generate_uuid=function(){var a=(new Date).getTime(),b="xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(b){var c=(a+16*Math.random())%16|0;return a=Math.floor(a/16),("x"===b?c:7&c|8).toString(16)});return b},d.get_client_id=function(){var a=d.get_cookies()._tdim||d.generate_uuid();return d.set_cookie("_tdim",a,365),a},d.base64_encode=function(a){var b="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";a=unescape(encodeURIComponent(a));for(var c,d,e,f,g,h,i,j="",k=0;k<a.length;)c=a.charCodeAt(k++),d=a.charCodeAt(k++),e=a.charCodeAt(k++),f=c>>2,g=(3&c)<<4|d>>4,h=(15&d)<<2|e>>6,i=63&e,isNaN(d)?h=i=64:isNaN(e)&&(i=64),j=j+b.charAt(f)+b.charAt(g)+b.charAt(h)+b.charAt(i);return j},d.stringify=function(a){var c;if(b.JSON&&b.JSON.stringify)c=JSON.stringify(a);else{var d=function(a){var b=typeof a;if("object"!=b||null===a)return"string"==b&&(a='"'+a.split('"').join('\\"')+'"'),String(a);var c,e,f=[],g=a&&a.constructor==Array;for(c in a)e=a[c],b=typeof e,"string"==b?e='"'+e.split('"').join('\\"')+'"':"object"==b&&null!==e&&(e=d(e)),f.push((g?"":'"'+c+'":')+String(e));return(g?"[":"{")+String(f)+(g?"]":"}")};c=d(a)}return c},d.create_script_tag=function(a){var b=c.createElement("script");b.type="text/javascript",b.async=!0,b.src=a;var d=c.getElementsByTagName("script")[0];d.parentNode.insertBefore(b,d)},d.fire_gtm_event=function(a,c){var d;for(var e in c)c.hasOwnProperty(e)&&(d={},d[e]=c[e],b[a].push(d))},b[a].callback=b[a].callback||{},b[a].static_functions=d,b[a].prototype.init=function(){var c={ts:(new Date).getTime(),id:"tij"+(new Date).getTime()+(1e3+Math.floor(9e3*Math.random())),data:{},debug:!1,imid:void 0,imuid:void 0,sids:[],td_host:"in.treasuredata.com",td_api_key:void 0,td_db:void 0,td_tb:"pageviews",gtm_dl:void 0,gtm_ev_name:"im-ready",im_api_token:void 0,im_api_host:"sync.im-apps.net",mtm_host:"b.im-apps.net",tracker_url_ipv6:"https://b6.im-apps.net/collect",mtm_enabled:!0,mtm_site_id:void 0};for(var d in c)c.hasOwnProperty(d)&&(this[d]=this[d]||c[d]);b[a].callback[this.id]=this},b[a].prototype.log=function(a){this.debug&&(a="[debug]["+this.id+"]"+a,b.console&&b.console.log(a))},b[a].prototype.collect_pv_data=function(){var a={};return a.td_client_id=d.get_client_id(),a.td_charset=(c.characterSet||c.charset||"-").toLowerCase(),a.td_language=function(){var a=b.navigator;return(a&&(a.language||a.browserLanguage)||"-").toLowerCase()}(),a.td_color=b.screen?b.screen.colorDepth+"-bit":"-",a.td_screen=b.screen?b.screen.width+"x"+b.screen.height:"-",a.td_title=c.title,a.td_url=c.location.href.split("#")[0],a.td_host=c.location.host,a.td_path=c.location.pathname,a.td_referrer=c.referrer,a.td_ip="td_ip",a.td_browser="td_browser",a.td_browser_version="td_browser_version",a.td_os="td_os",a.td_os_version="td_os_version",a.td_viewport=function(){var a=c.documentElement&&c.documentElement.clientHeight,d=c.documentElement&&c.documentElement.clientWidth,e=a<b.innerHeight?b.innerHeight:a,f=d<b.innerWidth?b.innerWidth:d;return f+"x"+e}(),a.td_user_agent=b.navigator.userAgent,a.td_platform=b.navigator.platform,a.td_version="tdimjs"+d.version,a},b[a].prototype.td_send_imid=function(b,c){if(this.td_tb=b||this.td_tb,c=c||{},!this.im_api_token)return void this.log("[error] im_api_token not found");for(var e in c)c.hasOwnProperty(e)&&(this.data[e]=c[e]);var f="https://"+this.im_api_host+"/imid/segment?token="+this.im_api_token+"&callback="+encodeURIComponent(a+".callback."+this.id+".im_callback")+"&need_created=True";d.create_script_tag(f),this.log("loading imid,sids")},b[a].prototype.after_im_callback=function(a){return a},b[a].prototype.im_callback=function(a){a=this.after_im_callback(a);var c=d.stringify(a);if(this.log("im_callback ... "+c),a.imid&&(this.imid=a.imid,this.data.imid=a.imid),a.imid_created&&(this.data.imid_created=a.imid_created),a.imuid&&(this.imuid=a.imuid,this.data.imuid=a.imuid),a.segment_eids&&(this.sids=a.segment_eids,this.data.segment_eids=a.segment_eids.join("|")),this.gtm_dl&&b[this.gtm_dl]){var e={imid:this.imid,segment_eids:this.sids.join("|"),event:this.gtm_ev_name};this.imuid&&(e.imuid=this.imuid),d.fire_gtm_event(this.gtm_dl,e)}this.td_send(this.td_tb,this.data)},b[a].prototype.td_send=function(b,c){if(this.td_tb=b||this.td_tb,c=c||{},!(this.td_api_key&&this.td_db&&this.td_tb))return void this.log("[error] td_api_key,td_db,td_tb are required");var e,f=this.data;for(e in c)c.hasOwnProperty(e)&&(f[e]=c[e]);var g=this.collect_pv_data();for(e in g)g.hasOwnProperty(e)&&(f[e]=f[e]||g[e]);f=this.before_send(f);var h=d.stringify(f);this.log("td_send ... "+h);var i="//"+this.td_host+"/js/v3/event/"+this.td_db+"/"+this.td_tb;i=i+"?api_key="+encodeURIComponent(this.td_api_key)+"&data="+encodeURIComponent(d.base64_encode(h)),i=i+"&modified="+this.ts+"&callback="+encodeURIComponent(a+".callback."+this.id+".td_callback"),0!=this.td_api_key.indexOf("312/")?d.create_script_tag(i):this.mtm_send(b,c)},b[a].prototype.mtm_send=function(a,d){if(this.mtm_enabled){var e=this.mtm_site_id;if("pageviews"===a&&!e){var f=this.td_db.match(/^(cosmi_)?([0-9]{4,7})$/);f&&f[2]&&(e=f[2])}e||(e=6,d.db_td=this.td_db+"."+a),d=d||{};var g,h=["imid","imid_created","imuid","segment_eids","im_cv_flag","im_score","active_sec","pv_cnt","session_cnt","partner_id_aam","partner_id_bk","partner_id_ga","partner_id_karte","partner_id_mrkt","partner_id_rtoaster"],i={};for(g in d)d.hasOwnProperty(g)&&h.indexOf(g)==-1&&!g.match(/^td_/)&&(i[g]=d[g]);!function(a,b,c,d){if(!b[a]){b[a]=function(){b[a].instances.push(this),this.init&&this.init()},b[a].instances=[];for(var e=0,f=["pageview"],g=f.length;e<g;e++)b[a].prototype[f[e]]=function(a){return function(){this["tmp_"+a]=this["tmp_"+a]||[],this["tmp_"+a].push(Array.prototype.slice.call(arguments))}}(f[e]);var h=c.getElementsByTagName("script")[0],i=c.createElement("script");i.async=!0,i.src=d,h.parentNode.insertBefore(i,h)}}("IMLOG",b,c,"//dmp.im-apps.net/sdk/log.js");var j=new IMLOG;j.siteId=e,j.trackerUrl="https://"+this.mtm_host+"/tracker",d.segment_eids?j.segment_eids=d.segment_eids:this.data.segment_eids&&(j.segment_eids=this.data.segment_eids),d.im_cv_flag&&(j.cvid=d.im_cv_flag),d.im_score&&(j.score=d.im_score),j.pageview(i);var k=new IMLOG;k.siteId=e,k.trackerUrl=this.tracker_url_ipv6,k.pageview(i)}},b[a].prototype.before_send=function(a){return a},b[a].prototype.td_callback=function(a){a.created?this.log("td_callback ... success!"):this.log("td_callback ... failed!!")},function(){for(var c,d,e=0;e<b[a].instances.length;e++){c=b[a].instances[e],c.init();for(var f=0,g=["td_send","td_send_imid"];f<g.length;f++)if(d="tmp_"+g[f],c[d])for(var h=0;h<c[d].length;h++)c[g[f]].apply(c,c[d][h])}}()}("TDIM",window,document);