 /* document.write('<div class="loader-w74e62130cc5090097a5bed94dfe29471"></div>'); */ /** http://jquerymy.com/js/md5.js */ var md5=(function(){function e(e,t){var o=e[0],u=e[1],a=e[2],f=e[3];o=n(o,u,a,f,t[0],7,-680876936);f=n(f,o,u,a,t[1], 12,-389564586);a=n(a,f,o,u,t[2],17,606105819);u=n(u,a,f,o,t[3],22,-1044525330);o=n(o,u,a,f,t[4],7,-176418897);f=n(f,o,u,a,t[5], 12,1200080426);a=n(a,f,o,u,t[6],17,-1473231341);u=n(u,a,f,o,t[7],22,-45705983);o=n(o,u,a,f,t[8],7,1770035416);f=n(f,o,u,a,t[9], 12,-1958414417);a=n(a,f,o,u,t[10],17,-42063);u=n(u,a,f,o,t[11],22,-1990404162);o=n(o,u,a,f,t[12],7,1804603682);f=n(f,o,u,a,t[13], 12,-40341101);a=n(a,f,o,u,t[14],17,-1502002290);u=n(u,a,f,o,t[15],22,1236535329);o=r(o,u,a,f,t[1],5,-165796510);f=r(f,o,u,a,t[6], 9,-1069501632);a=r(a,f,o,u,t[11],14,643717713);u=r(u,a,f,o,t[0],20,-373897302);o=r(o,u,a,f,t[5],5,-701558691);f=r(f,o,u,a,t[10], 9,38016083);a=r(a,f,o,u,t[15],14,-660478335);u=r(u,a,f,o,t[4],20,-405537848);o=r(o,u,a,f,t[9],5,568446438);f=r(f,o,u,a,t[14], 9,-1019803690);a=r(a,f,o,u,t[3],14,-187363961);u=r(u,a,f,o,t[8],20,1163531501);o=r(o,u,a,f,t[13],5,-1444681467);f=r(f,o,u,a,t[2], 9,-51403784);a=r(a,f,o,u,t[7],14,1735328473);u=r(u,a,f,o,t[12],20,-1926607734);o=i(o,u,a,f,t[5],4,-378558);f=i(f,o,u,a,t[8], 11,-2022574463);a=i(a,f,o,u,t[11],16,1839030562);u=i(u,a,f,o,t[14],23,-35309556);o=i(o,u,a,f,t[1],4,-1530992060);f=i(f,o,u,a,t[4], 11,1272893353);a=i(a,f,o,u,t[7],16,-155497632);u=i(u,a,f,o,t[10],23,-1094730640);o=i(o,u,a,f,t[13],4,681279174);f=i(f,o,u,a,t[0], 11,-358537222);a=i(a,f,o,u,t[3],16,-722521979);u=i(u,a,f,o,t[6],23,76029189);o=i(o,u,a,f,t[9],4,-640364487);f=i(f,o,u,a,t[12], 11,-421815835);a=i(a,f,o,u,t[15],16,530742520);u=i(u,a,f,o,t[2],23,-995338651);o=s(o,u,a,f,t[0],6,-198630844);f=s(f,o,u,a,t[7], 10,1126891415);a=s(a,f,o,u,t[14],15,-1416354905);u=s(u,a,f,o,t[5],21,-57434055);o=s(o,u,a,f,t[12],6,1700485571);f=s(f,o,u,a,t[3], 10,-1894986606);a=s(a,f,o,u,t[10],15,-1051523);u=s(u,a,f,o,t[1],21,-2054922799);o=s(o,u,a,f,t[8],6,1873313359);f=s(f,o,u,a,t[15], 10,-30611744);a=s(a,f,o,u,t[6],15,-1560198380);u=s(u,a,f,o,t[13],21,1309151649);o=s(o,u,a,f,t[4],6,-145523070);f=s(f,o,u,a,t[11], 10,-1120210379);a=s(a,f,o,u,t[2],15,718787259);u=s(u,a,f,o,t[9],21,-343485551);e[0]=m(o,e[0]);e[1]=m(u,e[1]);e[2]=m(a,e[2]);e[3]=m(f,e[3])} function t(e,t,n,r,i,s){t=m(m(t,e),m(r,s));return m(t<<i|t>>>32-i,n)}function n(e,n,r,i,s,o,u){return t(n&r|~n&i,e,n,s,o,u)} function r(e,n,r,i,s,o,u){return t(n&i|r&~i,e,n,s,o,u)}function i(e,n,r,i,s,o,u){return t(n^r^i,e,n,s,o,u)} function s(e,n,r,i,s,o,u){return t(r^(n|~i),e,n,s,o,u)}function o(t){var n=t.length,r=[1732584193,-271733879,-1732584194,271733878],i; for(i=64;i<=t.length;i+=64){e(r,u(t.substring(i-64,i)))}t=t.substring(i-64);var s=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]; for(i=0;i<t.length;i++)s[i>>2]|=t.charCodeAt(i)<<(i%4<<3);s[i>>2]|=128<<(i%4<<3);if(i>55){e(r,s);for(i=0;i<16;i++)s[i]=0}s[14]=n*8;e(r,s);return r} function u(e){var t=[],n;for(n=0;n<64;n+=4){t[n>>2]=e.charCodeAt(n)+(e.charCodeAt(n+1)<<8)+(e.charCodeAt(n+2)<<16)+(e.charCodeAt(n+3)<<24)}return t} function c(e){var t="",n=0;for(;n<4;n++)t+=a[e>>n*8+4&15]+a[e>>n*8&15];return t} function h(e){for(var t=0;t<e.length;t++)e[t]=c(e[t]);return e.join("")} function d(e){return h(o(unescape(encodeURIComponent(e))))} function m(e,t){return e+t&4294967295}var a="0123456789abcdef".split("");return d})(); var widget_jqVersion = "1.10.2"; if(typeof WidgetLoader==="undefined") { if(typeof jQuery==="undefined"||jQuery.fn.jquery!==widget_jqVersion) { if(docHead=document.getElementsByTagName("head")[0]) { var s = document.createElement("script"); s.setAttribute("type","text/javascript"); s.src = location.protocol+"\/\/wyoming.reaproject.org\/ext\/js\/jquery-"+widget_jqVersion+".min.js"; var jqLoadInterval = window.setInterval(function() { if(typeof jQuery!=="undefined"&&jQuery.fn.jquery===widget_jqVersion) { window.self.clearInterval(jqLoadInterval); jQuery.noConflict(); } },100); docHead.appendChild(s); } } var WidgetLoader = function(id,parent_id,src,domain,img_url,scroll_type,src_page) { var _this = this; _this.id = id; _this.parent_id = 'w'+md5(window.location.href); _this.i$ = null; _this.src = src; _this.domain = domain; _this.img_url = img_url; _this.scroll_type = scroll_type; _this.required_jquery_version = widget_jqVersion; _this.ready = false; _this.readyInterval = null; _this.debug = false; this.init = function() { if(typeof jQuery!=="undefined"&&jQuery.fn.jquery===_this.required_jquery_version&&!_this.i$) { var p$ = jQuery(document.createElement("img")); p$.prop("src",this.img_url).css("float","none"); _this.i$ = jQuery(document.createElement("iframe")); _this.i$.attr("id",_this.id); _this.i$.attr("frameborder","0"); _this.i$.attr("allowTransparency",true); _this.i$.attr("seamless","seamless"); _this.i$.attr("scrolling","no"); _this.i$.css("overflow","hidden"); _this.i$.css("padding","0px"); _this.readyInterval = window.setInterval(function() { if(_this.ready) { window.clearInterval(_this.readyInterval); _this.readyInterval = null; p$.toggle(false); _this.i$.toggle(true); _this.sendMsgDown("getDimensions"); } },500); _this.i$.toggle(false); var d$ = jQuery(document.createElement("div")); d$.css("text-align","center").append(p$).append(_this.i$); var script$ = jQuery("script[src^='"+_this.domain+"']") .add("script[src^='"+_this.domain.replace(/^https/gi,'http')+"']"); script$ = script$.filter(function(i,e) { var src = jQuery(e).attr('src'); return jQuery(e).is("[src$='loader.js']") || (src.match(/loader\.js\?.*$/gi)); }); if(script$.length>1) { script$ = script$.filter("script[src^='"+_this.src+"loader.js']").eq(0); } loader$ = jQuery("div.loader-"+_this.id); if(script$.length) { script$.after(d$); } else { loader$.after(d$); } loader$.remove(); _this.i$.prop("src",_this.src+((src_page)?"#"+src_page:"")); } }; this.sendResizeMsg = function() { if(window.parent&&window.self!==window.top&&_this.parent_id) { if(_this.debug) { console.log('Sending: sendResizeMsg: For: '+_this.parent_id); } window.parent.postMessage('{"func":"onresize","id":"'+_this.parent_id+'"}',"*"); } }; this.sendReadyMsg = function() { if(window.parent&&window.self!==window.top&&_this.parent_id) { if(_this.debug) { console.log('Sending: sendReadyMsg: For: '+_this.parent_id); } window.parent.postMessage('{"func":"onready","id":"'+_this.parent_id+'"}',"*"); } }; this.sendScrollMsg = function(x,y) { if(window.parent&&window.self!==window.top&&_this.parent_id) { if(_this.debug) { console.log('Sending: sendScrollMsg: For: '+_this.parent_id+': '+x+','+y); } window.parent.postMessage('{"func":"scroll","id":"'+_this.parent_id+'","x":"'+x+'","y":"'+y+'"}',"*"); } }; this.sendMsgDown = function(msg) { if(_this.i$&&_this.i$.get(0).contentWindow&&_this.domain) { try { if(_this.debug) { console.log('Sending: sendMsgDown: '+msg+' To:'+_this.id); } _this.i$.get(0).contentWindow.postMessage('{ "func":"'+msg+'", "id":"'+_this.id+'", "width":"'+_this.i$.width()+'", "height":"'+_this.i$.height()+'" }',_this.domain); } catch(e) { console.log(e.message); } } }; this.receiveMsg = function(msg) { if(_this.i$) { var f = (msg.data && msg.data.func && msg.data.func.match(/^[a-z]+$/gi)) ? String(msg.data.func) : null; var id = (msg.data) ? String(msg.data.id) : null; if(msg.origin&&f&&id) { switch(f) { case "setDimensions": if(msg.origin===_this.domain && String(msg.data.id)===_this.id) { if(_this.debug) { console.log('Received: setDimensions: '+msg.data.width+' x '+msg.data.height+' For:'+_this.id); } w = parseInt(msg.data.width); h = parseInt(msg.data.height); if(w&&h) { _this.i$.css("min-width",w+"px").css("width",w+"px"); _this.i$.css("min-height",h+"px").css("height",h+"px"); switch(_this.scroll_type) { case "top": window.scrollTo(_this.i$.offset().left,0); break; case "auto": window.scrollTo(_this.i$.offset().left,_this.i$.offset().top); break; case "none": default: break; } } window.setTimeout(function() { _this.sendResizeMsg(); },50); } break; case "getDimensions": if(String(msg.data.id)===_this.parent_id) { if(_this.debug) { console.log('Received: getDimensions: '+msg.data.width+' x '+msg.data.height+' From:'+_this.parent_id); } if((c$=$("body > div.widget-container")).length) { var w = parseInt(msg.data.width); var h = parseInt(msg.data.height); var new_w = (c$.width()+30); var new_h = (c$.height()+20); if(new_w!=w||new_h!=h) { if(_this.debug) { console.log('Sending: setDimensions: '+new_w+' x '+new_h+' For:'+id); } msg.source.postMessage('{'+ '"func":"setDimensions",'+ '"id":"'+id+'",'+ '"width":'+new_w+','+ '"height":'+new_h+ '}',msg.origin); } } else { if(_this.debug) { console.log(id+': body > div.widget-contianer not found'); } } } break; case "scroll": if(msg.origin===_this.domain && String(msg.data.id)===_this.id) { if(_this.debug) { console.log('Received: scroll: '+msg.data.x+' x '+msg.data.y+' For:'+_this.id); } var offset_x = parseInt(_this.i$.offset().left) + parseInt(msg.data.x); var offset_y = parseInt(_this.i$.offset().top) + parseInt(msg.data.y); if(window.self!==window.top) { window.setTimeout(function() { _this.sendScrollMsg(offset_x,offset_y); },50); } else { if(_this.debug) { console.log('Scrolling Window To '+offset_x+','+offset_y+': For: '+_this.id); } window.scrollTo(offset_x,offset_y); } } break; case "onresize": if(msg.origin===_this.domain && String(msg.data.id)===_this.id) { if(_this.debug) { console.log('Received: onresize: For:'+_this.id); } _this.sendMsgDown("getDimensions"); } break; case "onready": if(msg.origin===_this.domain && String(msg.data.id)===_this.id) { if(_this.debug) { console.log('Received: onready: For:'+_this.id); } if(_this.readyInterval) { _this.ready = true; } else { _this.sendMsgDown("getDimensions"); } } break; default: break; } } } }; }; } if(!scroll_type) { var scroll_type = "auto"; } var w74e62130cc5090097a5bed94dfe29471 = new WidgetLoader( "w74e62130cc5090097a5bed94dfe29471", "wd41d8cd98f00b204e9800998ecf8427e", "https://wyoming.reaproject.org/data-tables/economic-profiles-ca30/widgets/74490000/", "https://wyoming.reaproject.org", "https://www.reaproject.org/img/processing/560000_please_wait.gif", scroll_type, null ); window.w74e62130cc5090097a5bed94dfe29471Interval = window.setInterval(function() { if(typeof jQuery!=="undefined"&&jQuery.fn.jquery===w74e62130cc5090097a5bed94dfe29471.required_jquery_version) { window.clearInterval(w74e62130cc5090097a5bed94dfe29471Interval); jQuery(window.self).on("message",function(event) { try { w74e62130cc5090097a5bed94dfe29471.receiveMsg({ "origin":event.originalEvent.origin, "data":jQuery.parseJSON(event.originalEvent.data), "source":event.originalEvent.source }); } catch(e) { console.log(e.message); } }); jQuery(document).ready(function() { w74e62130cc5090097a5bed94dfe29471.sendReadyMsg(); }); w74e62130cc5090097a5bed94dfe29471.init(); } },50); 