require.def("core/lib",["core/trace"],function(a){var b={},c=navigator.userAgent.toLowerCase();b.isFirefox=/firefox/.test(c),b.isOpera=/opera/.test(c),b.isWebkit=/webkit/.test(c),b.isSafari=/webkit/.test(c),b.isIE=/msie/.test(c)&&!/opera/.test(c),b.isIE6=/msie 6/i.test(navigator.appVersion),b.browserVersion=(c.match(/.+(?:rv|it|ra|ie)[\/: ]([\d.]+)/)||[0,"0"])[1],b.isIElt8=b.isIE&&b.browserVersion-0<8,b.extend=function d(a,c){var d={};b.append(d,a),b.append(d,c);return d},b.append=function(a,b){for(var c in b)a[c]=b[c];return a},b.bind=function(){var a=b.cloneArray(arguments),c=a.shift(),d=a.shift();return function(){return c.apply(d,b.arrayInsert(b.cloneArray(a),0,arguments))}},b.bindFixed=function(){var a=b.cloneArray(arguments),c=a.shift(),d=a.shift();return function(){return c.apply(d,a)}},b.dispatch=function(b,c,d){for(var e=0;b&&e=a.top&&c<=a.top+a.height&&b>=a.left&&b<=a.left+a.width},b.cloneArray=function(a,b){var c=[];if(b)for(var d=0;d2?2:b,b=b<-1?-1:b;if(b==-1)return a+" B";var c=Math.pow(10,b);return a==-1||a==undefined?"?":a==0?"0":a<1024?a+" B":a<1048576?Math.round(a/1024*c)/c+" KB":Math.round(a/1048576*c)/c+" MB"},b.formatTime=function(a){return a==-1?"-":a<1e3?a+"ms":a<6e4?Math.ceil(a/10)/100+"s":Math.ceil(a/6e4*100)/100+"m"},b.formatNumber=function(a){a+="";var b=a.split("."),c=b[0],d=b.length>1?"."+b[1]:"",e=/(\d+)(\d{3})/;while(e.test(c))c=c.replace(e,"$1 $2");return c+d},b.formatString=function(a){var c=b.cloneArray(arguments),a=c.shift();for(var d=0;d0?"-":"+")+b(Math.abs(e))+":"+b(Math.abs(f));return c+g},b.getFileName=function(c){try{var d=b.splitURLBase(c);return d.name}catch(e){a.log(unescape(c))}return c},b.getFileExtension=function(a){if(!a)return null;var b=a.indexOf("?");b!=-1&&(a=a.substr(0,b));var c=a.lastIndexOf(".");return a.substr(c+1)},b.splitURLBase=function(a){if(b.isDataURL(a))return b.splitDataURL(a);return b.splitURLTrue(a)},b.isDataURL=function(a){return a&&a.substr(0,5)=="data:"},b.splitDataURL=function(a){var c=a.indexOf(":",3);if(c!=4)return!1;var d=a.indexOf(",",c+1);if(d"+l}else e.name=k.name,e.path=k.path}else e.hasOwnProperty("path")||(e.path="data:"),e.hasOwnProperty("name")||(e.name=decodeURIComponent(e.encodedContent.substr(0,200)).replace(/\s*$/,""));return e},b.splitURLTrue=function(a){var b=/:\/{1,3}(.*?)\/([^\/]*?)\/?($|\?.*)/,c=b.exec(a);return c?c[2]?{path:c[1],name:c[2]+c[3]}:{path:c[1],name:c[1]}:{name:a,path:a}},b.getURLParameter=function(a){var b=window.location.search.substring(1),c=b.split("&");for(var d=0;dd&&!c&&(k=b.$STR("LargeData")),e.push({name:f(j),value:f(k)})}else{var j=g[h];e.push({name:f(j),value:""})}}catch(l){}e.sort(function(a,b){return a.name<=b.name?-1:1});return e},b.getBody=function(a){if(a.body)return a.body;var b=a.getElementsByTagName("body")[0];if(b)return b;return null},b.getHead=function(a){return a.getElementsByTagName("head")[0]},b.getAncestorByClass=function(a,c){for(var d=a;d;d=d.parentNode)if(b.hasClass(d,c))return d;return null},b.$=function(){return b.getElementByClass.apply(this,arguments)},b.getElementByClass=function(a,c){if(!a)return null;var d=b.cloneArray(arguments);d.splice(0,1);for(var e=a.firstChild;e;e=e.nextSibling){var f=b.cloneArray(d);f.unshift(e);if(b.hasClass.apply(this,f))return e;var g=b.getElementByClass.apply(this,f);if(g)return g}return null},b.getElementsByClass=function(a,c){function f(a,c,d){for(var e=a.firstChild;e;e=e.nextSibling){var g=b.cloneArray(c);g.unshift(e),b.hasClass.apply(null,g)&&d.push(e),f(e,c,d)}}if(a.querySelectorAll){var d=b.cloneArray(arguments);d.shift();var e="."+d.join(".");return a.querySelectorAll(e)}var g=[],d=b.cloneArray(arguments);d.shift(),f(a,d,g);return g},b.getChildByClass=function(a){for(var c=1;c=0){var d=b.length;a.className=a.className.substr(0,c-1)+a.className.substr(c+d)}}},b.toggleClass=function(a,c){if(b.hasClass(a,c)){b.removeClass(a,c);return!1}b.setClass(a,c);return!0},b.setClassTimed=function(a,c,d){d||(d=1300),a.__setClassTimeout?clearTimeout(a.__setClassTimeout):b.setClass(a,c),a.__setClassTimeout=setTimeout(function(){delete a.__setClassTimeout,b.removeClass(a,c)},d)},b.trim=function(a){return a.replace(/^\s*|\s*$/g,"")},b.wrapText=function(a,c){var d=/[^A-Za-z_$0-9'"-]/,e=[],f=100,g=b.splitLines(a);for(var h=0;hf){var j=d.exec(i.substr(f,100)),k=f+(j?j.index:0),l=i.substr(0,k);i=i.substr(k),c||e.push("
"),e.push(c?l:b.escapeHTML(l)),c||e.push("
")}c||e.push("
"),e.push(c?i:b.escapeHTML(i)),c||e.push("
")}return e.join(c?"\n":"")},b.insertWrappedText=function(a,c,d){c.innerHTML="
"+b.wrapText(a,d)+"
"},b.splitLines=function(a){var b=/\r\n|\r|\n/;if(!a)return[];if(a.split)return a.split(b);var c=a+"",d=c.split(b);return d},b.getPrettyDomain=function(a){var b=/[^:]+:\/{1,3}(www\.)?([^\/]+)/.exec(a);return b?b[2]:""},b.escapeHTML=function(a){function b(a){switch(a){case"<":return"<";case">":return">";case"&":return"&";case"'":return"'";case'"':return"""}return"?"}return String(a).replace(/[<>&"']/g,b)},b.cropString=function(a,c){a=a+"";if(c)var d=c/2;else var d=50;return a.length>c?b.escapeNewLines(a.substr(0,d)+"..."+a.substr(a.length-d)):b.escapeNewLines(a)},b.escapeNewLines=function(a){return a.replace(/\r/g,"\\r").replace(/\n/g,"\\n")},b.cloneJSON=function(b){if(b==null||typeof b!="object")return b;try{var c=b.constructor();for(var d in b)c[d]=this.cloneJSON(b[d]);return c}catch(e){a.exception(e)}return null},b.getOverflowParent=function(a){for(var b=a.parentNode;b;b=b.offsetParent)if(b.scrollHeight>b.offsetHeight)return b},b.getElementBox=function(a){var c={};if(a.getBoundingClientRect){var d=a.getBoundingClientRect(),e=b.isIE?document.body.clientTop||document.documentElement.clientTop:0,f=b.getWindowScrollPosition();c.top=Math.round(d.top-e+f.top),c.left=Math.round(d.left-e+f.left),c.height=Math.round(d.bottom-d.top),c.width=Math.round(d.right-d.left)}else{var g=b.getElementPosition(a);c.top=g.top,c.left=g.left,c.height=a.offsetHeight,c.width=a.offsetWidth}return c},b.getElementPosition=function(a){var b=0,c=0;do b+=a.offsetLeft,c+=a.offsetTop;while(a=a.offsetParent);return{left:b,top:c}},b.getWindowSize=function(){var a=0,b=0,c;typeof window.innerWidth=="number"?(a=window.innerWidth,b=window.innerHeight):(c=document.documentElement)&&(c.clientHeight||c.clientWidth)?(a=c.clientWidth,b=c.clientHeight):(c=document.body)&&(c.clientHeight||c.clientWidth)&&(a=c.clientWidth,b=c.clientHeight);return{width:a,height:b}},b.getWindowScrollSize=function(){var a=0,c=0,d;!b.isIEQuiksMode&&(d=document.documentElement)&&(d.scrollHeight||d.scrollWidth)&&(a=d.scrollWidth,c=d.scrollHeight),(d=document.body)&&(d.scrollHeight||d.scrollWidth)&&(d.scrollWidth>a||d.scrollHeight>c)&&(a=d.scrollWidth,c=d.scrollHeight);return{width:a,height:c}},b.getWindowScrollPosition=function(){var a=0,b=0,c;typeof window.pageYOffset=="number"?(a=window.pageYOffset,b=window.pageXOffset):(c=document.body)&&(c.scrollTop||c.scrollLeft)?(a=c.scrollTop,b=c.scrollLeft):(c=document.documentElement)&&(c.scrollTop||c.scrollLeft)&&(a=c.scrollTop,b=c.scrollLeft);return{top:a,left:b}},b.scrollIntoCenterView=function(a,c,d,e){if(a){c||(c=b.getOverflowParent(a));if(!c)return;var f=b.getClientOffset(a);if(!e){var g=f.y-c.scrollTop,h=c.scrollTop+c.clientHeight-(f.y+a.offsetHeight);if(g<0||h<0){var i=f.y-c.clientHeight/2;c.scrollTop=i}}if(!d){var j=f.x-c.scrollLeft,k=c.scrollLeft+c.clientWidth-(f.x+a.clientWidth);if(j<0||k<0){var l=f.x-c.clientWidth/2;c.scrollLeft=l}}}},b.getClientOffset=function(a){function b(a,c,d){var e=a.offsetParent,f=d.getComputedStyle(a,"");a.offsetLeft&&(c.x+=a.offsetLeft+parseInt(f.borderLeftWidth)),a.offsetTop&&(c.y+=a.offsetTop+parseInt(f.borderTopWidth)),e?e.nodeType==1&&b(e,c,d):a.ownerDocument.defaultView.frameElement&&b(a.ownerDocument.defaultView.frameElement,c,a.ownerDocument.defaultView)}var c={x:0,y:0};if(a){var d=a.ownerDocument.defaultView;b(a,c,d)}return c},b.addStyleSheet=function(a,c){if(!a.getElementById(c)){var d=a.createElement("link");d.type="text/css",d.rel="stylesheet",d.href=c,d.setAttribute("id",c);var e=b.getHead(a);e.appendChild(d)}},b.selectElementText=function(a,b,c){var d=window,e=d.document;if(d.getSelection&&e.createRange){var f=d.getSelection(),g=e.createRange();g.setStart(a,b),g.setEnd(a,c),f.removeAllRanges(),f.addRange(g)}else e.body.createTextRange&&(g=e.body.createTextRange(),g.moveToElementText(a),g.select())};return b}),require.def("domplate/tabView",["domplate/domplate","core/lib","core/trace"],function(Domplate,Lib,Trace){with(Domplate){var TabViewTempl=domplate({tag:TABLE({"class":"tabView",cellpadding:0,cellspacing:0,_repObject:"$tabView"},TBODY(TR({"class":"tabViewRow"},TD({"class":"tabViewCol",valign:"top"},TAG("$tabList",{tabView:"$tabView"}))))),tabList:DIV({"class":"tabViewBody",onclick:"$onClickTab"},DIV({"class":"$tabView.id\\Bar tabBar"}),DIV({"class":"$tabView.id\\Bodies tabBodies"})),tabHeaderTag:A({"class":"$tab.id\\Tab tab",view:"$tab.id",_repObject:"$tab"},"$tab.label"),tabBodyTag:DIV({"class":"tab$tab.id\\Body tabBody",_repObject:"$tab"}),hideTab:function(a){return!1},onClickTab:function(a){var b=Lib.fixEvent(a),c=this.getTabView(b.target);c.onClickTab(b)},getTabView:function(a){var b=Lib.getAncestorByClass(a,"tabView");return b.repObject}});function TabView(a){this.id=a,this.tabs=[],this.listeners=[],this.tabBarVisibility=!0}TabView.prototype={appendTab:function(a){this.tabs.push(a),a.tabView=this;return a},removeTab:function(a){for(var b in this.tabs){var c=this.tabs[b];if(c.id==a){this.tabs.splice(b,1);break}}},getTab:function(a){for(var b in this.tabs){var c=this.tabs[b];if(c.id==a)return c}},selectTabByName:function(a){var b=Lib.getElementByClass(this.element,a+"Tab");b&&this.selectTab(b)},showTabBar:function(a){this.element?a?this.element.removeAttribute("hideTabBar"):this.element.setAttribute("hideTabBar","true"):this.tabBarVisibility=a},addListener:function(a){this.listeners.push(a)},removeListener:function(a){Lib.remove(this.listeners,a)},onClickTab:function(a){var b=Lib.getAncestorByClass(a.target,"tab");b&&this.selectTab(b)},selectTab:function(a){if(Lib.hasClass(a,"tab")){if(Lib.hasClass(a,"selected")&&a._updated)return;var b=a.getAttribute("view");if(!b)return;var c=Lib.getAncestorByClass(a,"tabViewBody");c.selectedTab&&(c.selectedTab.removeAttribute("selected"),c.selectedBody.removeAttribute("selected"),Lib.removeClass(c.selectedTab,"selected"),Lib.removeClass(c.selectedBody,"selected"));var d=Lib.getElementByClass(c,"tab"+b+"Body");d||Trace.error("TabView.selectTab; Missing tab body",a),c.selectedTab=a,c.selectedBody=d,c.selectedTab.setAttribute("selected","true"),c.selectedBody.setAttribute("selected","true"),Lib.setClass(c.selectedBody,"selected"),Lib.setClass(c.selectedTab,"selected"),this.updateTabBody(c,b)}},updateTabBody:function(a,b){var c=a.selectedTab.repObject;if(!c._body._updated){c._body._updated=!0,c.bodyTag&&c.bodyTag.replace({tab:c},c._body),c&&c.onUpdateBody&&c.onUpdateBody(this,c._body);for(var d=0;d-1&&(q=c[b]);b--){d=a[q];if(d===!0||d===1)d=e(j+q+"/"+l);require.mixin(o,d)}f(o)})})}})}(),define("nls/homeTab",{root:{homeTabLabel:"Home",loadingHar:"Loading..."}}),function(){var a=["Msxml2.XMLHTTP","Microsoft.XMLHTTP","Msxml2.XMLHTTP.4.0"],b=/^\s*<\?xml(\s)+version=[\'\"](\d)*.(\d)*[\'\"](\s)*\?>/im,c=/]*>\s*([\s\S]+)\s*<\/body>/im,d=[];define("text",["require","exports","module"],function(){var e,f,g;typeof window!=="undefined"&&window.navigator&&window.document?f=function(a,b){var c=e.createXhr();c.open("GET",a,!0),c.onreadystatechange=function(a){c.readyState===4&&b(c.responseText)},c.send(null)}:typeof process!=="undefined"&&process.versions&&!!process.versions.node?(g=require.nodeRequire("fs"),f=function(a,b){b(g.readFileSync(a,"utf8"))}):typeof Packages!=="undefined"&&(f=function(a,b){var c="utf-8",d=new java.io.File(a),e=java.lang.System.getProperty("line.separator"),f=new java.io.BufferedReader(new java.io.InputStreamReader(new java.io.FileInputStream(d),c)),g,h,i="";try{g=new java.lang.StringBuffer,h=f.readLine(),h&&h.length()&&h.charAt(0)===65279&&(h=h.substring(1)),g.append(h);while((h=f.readLine())!==null)g.append(e),g.append(h);i=String(g.toString())}finally{f.close()}b(i)}),e={version:"0.24.0",strip:function(a){if(a){a=a.replace(b,"");var d=a.match(c);d&&(a=d[1])}else a="";return a},jsEscape:function(a){return a.replace(/(['\\])/g,"\\$1").replace(/[\f]/g,"\\f").replace(/[\b]/g,"\\b").replace(/[\n]/g,"\\n").replace(/[\t]/g,"\\t").replace(/[\r]/g,"\\r")},createXhr:function(){var b,c,d;if(typeof XMLHttpRequest!=="undefined")return new XMLHttpRequest;for(c=0;c<3;c++){d=a[c];try{b=new ActiveXObject(d)}catch(e){}if(b){a=[d];break}}if(!b)throw new Error("require.getXhr(): XMLHttpRequest not available");return b},get:f,load:function(a,b,c,f){var g=!1,h,i=a.indexOf("."),j=a.substring(0,i),k=a.substring(i+1,a.length);i=k.indexOf("!"),i!==-1&&(g=k.substring(i+1,k.length),g=g==="strip",k=k.substring(0,i)),h=b.nameToUrl(j,"."+k),e.get(h,function(b){b=g?e.strip(b):b,f.isBuild&&f.inlineText&&(d[a]=b),c(b)})},write:function(a,b,c){if(b in d){var f=e.jsEscape(d[b]);c("define('"+a+"!"+b+"', function () { return '"+f+"';});\n")}}};return e})}(),define("text!tabs/homeTab.html",function(){return'
\r\n
    \r\n
  • Paste HAR\r\nlog into the text box below and\r\npress the Preview button.
  • \r\n
  • Or drop *.har file(s) anywhere on the page (if your browser supports that).
  • \r\n
\r\n\r\n \r\n \r\n \r\n \r\n
Validate data before processing?
\r\n\r\n

\r\n \r\n \r\n \r\n

\r\n
\r\n

HAR Log Examples

\r\n
    \r\n
  • \r\nInline scripts block - Inline scripts block the page load.
  • \r\n
  • \r\nBlocking time - Impact of a limit of max number of parallel connections.
  • \r\n
  • \r\nBrowser cache - Impact of the browser cache on page load (the same page loaded three times).
  • \r\n
  • \r\nSingle page - Single page load (empty cache).
  • \r\n
\r\n

HAR Logs Online

\r\nYou can also preview any HAR file (in JSONP format) that is available online by using\r\ninputUrl parameter
\r\n(see more in the About tab):

\r\n

\r\n http://www.softwareishard.com/har/viewer?inputUrl=http://www.janodvarko.cz/har/viewer/examples/inline-scripts-block.harp

\r\n\r\n
\r\n

This viewer supports HAR 1.2 (see the About tab).

\r\n
'}),require.def("preview/jsonSchema",[],function(){var a={validate:function(a,b){return this._validate(a,b,!1)},checkPropertyChange:function(a,b,c){return this._validate(a,b,c||"property")},_validate:function(a,b,c){function f(a,b,f,g){if(typeof b=="object"){(typeof a!="object"||a instanceof Array)&&d.push({property:f,message:"an object is required"});for(var h in b)if(b.hasOwnProperty(h)&&(h.charAt(0)!="_"||h.charAt(1)!="_")){var i=a[h],j=b[h];e(i,j,f,h)}}for(h in a){a.hasOwnProperty(h)&&(h.charAt(0)!="_"||h.charAt(1)!="_")&&b&&!b[h]&&g===!1&&d.push({property:f,message:typeof i+"The property "+h+" is not defined in the schema and the schema does not allow additional properties"});var k=b&&b[h]&&b[h].requires;k&&!(k in a)&&d.push({property:f,message:"the presence of the property "+h+" requires that "+k+" also be present"}),i=a[h],b&&typeof b=="object"&&!(h in b)&&e(i,g,f,h),!c&&i&&i.$schema&&(d=d.concat(e(i,i.$schema,f,h)))}return d}function e(a,b,g,h){function k(a,b){if(a){if(typeof a=="string"&&a!="any"&&(a=="null"?b!==null:typeof b!=a)&&!(b instanceof Array&&a=="array")&&(a!="integer"||b%1!==0))return[{property:g,message:typeof b+" value found, but a "+a+" is required"}];if(a instanceof Array){var c=[];for(var f=0;fb.maxItems&&j("There must be a maximum of "+b.maxItems+" in the array")}else b.properties&&d.concat(f(a,b.properties,g,b.additionalProperties));b.pattern&&typeof a=="string"&&!a.match(b.pattern)&&j("does not match the regex pattern "+b.pattern),b.maxLength&&typeof a=="string"&&a.length>b.maxLength&&j("may only be "+b.maxLength+" characters long"),b.minLength&&typeof a=="string"&&a.lengtha&&j("must have a minimum value of "+b.minimum),typeof b.maximum!==undefined&&typeof a==typeof b.maximum&&b.maximum=32&&b<127||b==10||b==13)return a.charAt(0);var c=b.toString(16).toUpperCase();while(c.length<4)c="0"+c;return"\\u"+c}).join("");return a}function h(){this.input=null}h.prototype={append:function(b){{if(b){b.log.entries.sort(function(b,c){var d=a.parseISO8601(b.startedDateTime),e=a.parseISO8601(c.startedDateTime);if(de)return 1;return 0});if(this.input){if(!b.log.pages){f.error("Import of additional data without a page is not yet supported.");return null}for(var c=0;c0?a[0]:null},getPageEntries:function(a){return h.getPageEntries(this.input,a)},getAllEntries:function(a){return this.input?this.input.log.entries:[]},getParentPage:function(a){return h.getParentPage(this.input,a)},importPage:function(a,b){var c=this.getUniquePageID(a.id),d=a.id;a.id=c,this.input.log.pages.push(a);for(var e=0;e0)&&h.length>0)return this.loadRemoteArchive(h,f,b,c);var j=a.getURLParameter("path");if(j)return this.loadLocalArchive(j,b,c)},loadExample:function(a,b){var c=document.location.href,d=c.indexOf("?");document.location=c.substr(0,d)+"?path="+a,e.setCookie("timeline",!0),e.setCookie("stats",!0)},loadLocalArchive:function(a,b,c){$.ajax({url:a,context:this,success:function(a){b(a)},error:function(a,b){c(a,b)}});return!0},loadRemoteArchive:function(a,b,c,d){if(!a.length)return!1;var e=a.shift();b||(b="onInputData"),$.ajax({url:e,context:this,dataType:"jsonp",jsonp:"callback",jsonpCallback:b,success:function(e){c&&c(e);if(a.length){var f=this;setTimeout(function(){f.loadRemoteArchive(a,b,c,d)},300)}},error:function(a,b){d&&d(a,b)}});return!0},load:function(a,b,c,d,e,f){function h(b,c){a.onLoadError&&a.onLoadError(b,c),f&&f.call(a,b,c)}function g(b){a.appendPreview&&a.appendPreview(b),e&&e.call(a,b)}return c?this.loadRemoteArchive([b],d,g,h):this.loadLocalArchive(b,g,h)}};return h}),require.def("tabs/homeTab",["domplate/domplate","domplate/tabView","core/lib","core/cookies","core/trace","i18n!nls/homeTab","text!tabs/homeTab.html","preview/harModel"],function(Domplate,TabView,Lib,Cookies,Trace,Strings,HomeTabHtml,HarModel){with(Domplate){function HomeTab(){}HomeTab.prototype=Lib.extend(TabView.Tab.prototype,{id:"Home",label:Strings.homeTabLabel,bodyTag:DIV({"class":"homeBody"}),onUpdateBody:function(a,b){b=this.bodyTag.replace({},b),b.innerHTML=HomeTabHtml.replace("@HAR_SPEC_URL@",a.harSpecURL,"g"),$("#appendPreview").click(Lib.bindFixed(this.onAppendPreview,this)),$(".linkAbout").click(Lib.bind(this.onAbout,this));var c=$("#content");c.bind("dragenter",Lib.bind(Lib.cancelEvent,Lib)),c.bind("dragover",Lib.bind(Lib.cancelEvent,Lib)),c.bind("drop",Lib.bind(this.onDrop,this)),this.validateNode=$("#validate");var d=Cookies.getCookie("validate");d&&this.validateNode.attr("checked",d=="false"?!1:!0),this.validateNode.change(Lib.bind(this.onValidationChange,this)),$(".example").click(Lib.bind(this.onLoadExample,this))},onAppendPreview:function(a){a||(a=$("#sourceEditor").val()),a&&this.tabView.appendPreview(a)},onAbout:function(){this.tabView.selectTabByName("About")},onValidationChange:function(){var a=this.validateNode.attr("checked");Cookies.setCookie("validate",a)},onLoadExample:function(a){var b=Lib.fixEvent(a),c=b.target.getAttribute("path"),d=document.location.href,e=d.indexOf("?");document.location=d.substr(0,e)+"?path="+c,Cookies.setCookie("timeline",!0),Cookies.setCookie("stats",!0)},onDrop:function(a){var b=Lib.fixEvent(a);Lib.cancelEvent(b);try{this.handleDrop(a.originalEvent.dataTransfer)}catch(c){Trace.exception("HomeTab.onDrop EXCEPTION",c)}},handleDrop:function(a){if(!a)return!1;var b=a.files;if(b)for(var c=0;c\r\n

HTTP Archive Viewer @VERSION@

\r\nAuthor: Jan Odvarko, odvarko@gmail.com\r\n

\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n
\r\n

The purpose of this online tool is to visualize\r\n\r\n HTTP Archive (HAR)\r\nlog files created by HTTP tracking tools. These files contain log of HTTP\r\nclient/server conversation and can be used for an additional analysis of e.g. \r\npage load performance.

\r\n\r\n

User interface of this tool is composed from the following tabs:

\r\n
    \r\n
  • Home - Paste content of a log file into the text box in this tab.
  • \r\n
  • Preview - Switch to this tab if you want to see visualised HTTP traffic.
  • \r\n
  • HAR - Use this tab to see structure of the input JSON data as an expandable tree.
  • \r\n
  • Schema - Explore format of the input log in this tab.
  • \r\n
\r\n
\r\n

Links

\r\n

Home Page (donate): \r\n http://www.softwareishard.com/blog/har-viewer/

\r\n

Feedback: \r\n http://groups.google.com/group/http-archive-specification

\r\n

Report issue: \r\n http://code.google.com/p/harviewer/issues/list

\r\n

HAR Viewer Customization: \r\n http://code.google.com/p/harviewer/wiki/Customization

\r\n
\r\n

Create HARs using Firebug

\r\nOne of the tools you can use to log data transfered over HTTP protocol\r\nis Firebug. To do this you have to also install Firebug\r\nextension called NetExport.\r\n
\r\n

HTTP Archive Specification

\r\n

Required\r\n\r\nstructure of the input HTTP Archive file (*.har) is described using\r\nJSON Schema.\r\nYou can explore the current schema definition within the Schema\r\ntab on this page.

\r\n
\r\n

Request Timing Fields

\r\n

Part of the HTTP log is also a timing info about network request executions.\r\nHere is a description of individual request/response phases:

\r\n
    \r\n
  • Blocking - Time spent in a queue waiting for a network connection.
  • \r\n
  • DNS Lookup - DNS resolution time. The time required to resolve a host name.
  • \r\n
  • Connecting - Time required to create TCP connection.
  • \r\n
  • Sending - Time required to send HTTP request to the server.
  • \r\n
  • Waiting - Waiting for a response from the server.
  • \r\n
  • Receiving - Time required to read entire response from the server (or cache).
  • \r\n
\r\n
\r\n

Online Log Files

\r\n

HAR Viewer also supports JSONP and so, it\'s possible to load log files \r\nfrom different domains. This allows linking your online logs and preview them\r\nautomatically within the viewer. See live\r\nexample.\r\n

\r\n\r\n

1. The Content of a *.har file must be enclosed within a callback function:

\r\nonInputData({ "log": { ... } })\r\n\r\n

2. The link displaying a *.har file (using this viewer) must specify URL of\r\nthe file in inputUrl parameter:

\r\nhttp://www.softwareishard.com/har/viewer/?inputUrl=http://www.example.com/netData.har\r\n\r\n

3. A custom name of the callback function can be specified in a callback parameter\r\n(by default it\'s onInputData):

\r\nhttp://www.softwareishard.com/har/viewer/?inputUrl=http://www.example.com/netData.har&callback=onInputData\r\n

\r\n
\r\n'}),define("nls/harViewer",{root:{aboutTabLabel:"About",schemaTabLabel:"Schema"}}),require.def("tabs/aboutTab",["domplate/domplate","domplate/tabView","core/lib","i18n!nls/harViewer"],function(Domplate,TabView,Lib,Strings){with(Domplate){function AboutTab(){}AboutTab.prototype={id:"About",label:Strings.aboutTabLabel,tabHeaderTag:A({"class":"$tab.id\\Tab tab",view:"$tab.id",_repObject:"$tab"},"$tab.label",SPAN(" "),SPAN({"class":"version"},"$tab.tabView.version")),bodyTag:DIV({"class":"aboutBody"}),onUpdateBody:function(a,b){var c=this;b=this.bodyTag.replace({},b),require(["text!tabs/aboutTab.html"],function(d){d=d.replace("@VERSION@",a.version,"g"),d=d.replace("@HAR_SPEC_URL@",a.harSpecURL,"g"),b.innerHTML=d,$(".linkSchema").click(Lib.bind(c.onSchema,c))})},onSchema:function(){this.tabView.selectTabByName("Schema")}};return AboutTab}}),define("nls/previewTab",{root:{previewTabLabel:"Preview",showTimelineButton:"Show Page Timeline",hideTimelineButton:"Hide Page Timeline",showTimelineTooltip:"Show/hide statistic preview for selected pages in the timeline.",showStatsButton:"Show Statistics",hideStatsButton:"Hide Statistics",showStatsTooltip:"Show/hide page timeline.",clearButton:"Clear",clearTooltip:"Remove all HAR logs from the viewer",downloadTooltip:"Download all current data in one HAR file.",downloadError:"Failed to save HAR data",menuShowHARSource:"Show HAR Source"}}),require.def("domplate/popupMenu",["domplate/domplate","core/lib","core/trace"],function(Domplate,Lib,Trace){with(Domplate){var Controller={controllers:[],controllerContext:{label:"controller context"},initialize:function(a){this.controllers=[],this.controllerContext=a||this.controllerContext},shutdown:function(){this.removeControllers()},addController:function(){for(var a=0,b;b=arguments[a];a++){typeof b[0]=="string"&&(b[0]=$$(b[0],this.controllerContext));var c=b[2];b[2]=Lib.bind(c,this),b[3]=c,this.controllers.push(b),Lib.addEventListener.apply(this,b)}},removeController:function(){for(var a=0,b;b=arguments[a];a++)for(var c=0,d;d=this.controllers[c];c++)b[0]==d[0]&&b[1]==d[1]&&b[2]==d[3]&&Lib.removeEventListener.apply(this,d)},removeControllers:function(){for(var a=0,b;b=this.controllers[a];a++)Lib.removeEventListener.apply(this,b)}},menuItemProps={"class":"$item.className",type:"$item.type",value:"$item.value",_command:"$item.command"};Lib.isIE6&&(menuItemProps.href="javascript:void(0)");var MenuPlate=domplate({tag:DIV({"class":"popupMenu popupMenuShadow"},DIV({"class":"popupMenuContent popupMenuShadowContent"},FOR("item","$object.items|memberIterator",TAG("$item.tag",{item:"$item"})))),itemTag:A(menuItemProps,"$item.label"),checkBoxTag:A(Lib.extend(menuItemProps,{checked:"$item.checked"}),"$item.label"),radioButtonTag:A(Lib.extend(menuItemProps,{selected:"$item.selected"}),"$item.label"),groupTag:A(Lib.extend(menuItemProps,{child:"$item.child"}),"$item.label"),shortcutTag:A(menuItemProps,"$item.label",SPAN({"class":"popupMenuShortcutKey"},"$item.key")),separatorTag:SPAN({"class":"popupMenuSeparator"}),memberIterator:function(a){var b=[];for(var c=0,d=a.length;c0&&this.maxElapsedTime>0&&(b=Math.round(c/this.maxElapsedTime*100));return Math.max(1,b)},onClick:function(a){var b=Lib.fixEvent(a),c=b.target;if(Lib.hasClass(c,"pageBar")){var d=Lib.isControlClick(b),e=Lib.isShiftClick(b),f=Lib.getAncestorByClass(c,"pageTimelineRow");!d&&!e&&Selection.unselectAll(f,c),Selection.toggle(c),this.selectionChanged()}},onMouseMove:function(a){var b=Lib.fixEvent(a),c=b.target;if(Lib.hasClass(c,"pageBar")){if(this.highlightedPage==c.page)return;this.highlightedPage=c.page;var d=Lib.getElementByClass(this.element,"pageDescContainer");Timeline.Desc.render(d,c)}},getPages:function(a){return a.log.pages?a.log.pages:[]},getPageBar:function(a){if(this.element){var b=Lib.getElementByClass(this.element,"pageTimelineTable"),c=b.firstChild.firstChild.firstChild;while(c){if(c.firstChild.page==a)return c.firstChild;c=c.nextSibling}}},recalcLayout:function(){this.maxElapsedTime=0;var a=this.maxElapsedTime,b=Lib.getElementsByClass(this.element,"pageBar");for(var c=0;c0&&this.maxElapsedTime0&&(b+=Strings.pageLoad+": "+Lib.formatTime(c)+", ");var d=HarModel.getPageEntries(a.input,a.page),e=d.length;b+=e+" "+(e==1?Strings.request:Strings.requests);return b},getTime:function(a){var b=Lib.parseISO8601(a.startedDateTime),c=new Date(b);return c.toLocaleString()},getTitle:function(a){return a.title},getComment:function(a){return a.comment?a.comment:""},render:function(a,b){var c={input:b.input,page:b.page},d=this.tag.replace({object:c},a),e=Lib.$(d,"connector");e.style.marginLeft=b.parentNode.offsetLeft+"px";return d}});var Selection={isSelected:function(a){return Lib.hasClass(a,"selected")},toggle:function(a){Lib.toggleClass(a,"selected")},select:function(a){this.isSelected(a)||Lib.setClass(a,"selected")},unselect:function(a){this.isSelected(a)&&Lib.removeClass(a,"selected")},getSelection:function(a){var b=[],c=Lib.getElementsByClass(a,"pageBar");for(var d=0;dk-this.infoTipWindowPadding?(a.style.left="auto",a.style.right=k-c+this.infoTipMargin+"px"):(a.style.left=c+this.infoTipMargin+"px",a.style.right="auto"),d+a.offsetHeight+this.infoTipMargin>l?(a.style.top=Math.max(0,l-(a.offsetHeight+this.infoTipMargin))+"px",a.style.bottom="auto"):(a.style.top=d+this.infoTipMargin+"px",a.style.bottom="auto"),a.setAttribute("active","true")}else this.hideInfoTip(a)},hideInfoTip:function(a){a&&a.removeAttribute("active")},onMouseOut:function(a){a.relatedTarget||this.hideInfoTip(this.infoTip)},onMouseMove:function(a){this.infoTip.setAttribute("multiline",!1);var b=a.clientX,c=a.clientY;this.showInfoTip(this.infoTip,a.target,b,c,a.rangeParent,a.rangeOffset)},populateTimingInfoTip:function(a,b){this.tags.colorTag.replace({rgbValue:b},a);return!0},addListener:function(a){this.listeners.push(a)},removeListener:function(a){Lib.remove(this.listeners,a)}});InfoTip.initialize();return InfoTip}}),require.def("tabs/pageStats",["domplate/domplate","core/lib","i18n!nls/pageStats","preview/harSchema","preview/harModel","core/cookies","domplate/infoTip","core/trace"],function(Domplate,Lib,Strings,HarSchema,HarModel,Cookies,InfoTip,Trace){with(Domplate){function Pie(){}Pie.prototype={data:[],title:"",getLabelTooltipText:function(a){return a.label+": "+Lib.formatSize(a.value)},cleanUp:function(){for(var a=0;a0?g.timings.ssl:0,timingPie.data[3].value+=g.timings.connect,timingPie.data[4].value+=g.timings.send,timingPie.data[5].value+=g.timings.wait,timingPie.data[6].value+=g.timings.receive,g.timings.ssl>0&&(timingPie.data[3].value-=g.timings.ssl);var h=g.response,i=h.bodySize>0?h.bodySize:0,j=h.content.mimeType,k=j?j.match(/^([^;]+)/)[1]:null,j=k?k:h.content.mimeType;htmlTypes[j]?(contentPie.data[0].value+=i,contentPie.data[0].count++):jsTypes[j]?(contentPie.data[1].value+=i,contentPie.data[1].count++):cssTypes[j]?(contentPie.data[2].value+=i,contentPie.data[2].count++):imageTypes[j]?(contentPie.data[3].value+=i,contentPie.data[3].count++):flashTypes[j]?(contentPie.data[4].value+=i,contentPie.data[4].count++):(contentPie.data[5].value+=i,contentPie.data[5].count++),trafficPie.data[0].value+=g.request.headersSize>0?g.request.headersSize:0,trafficPie.data[1].value+=g.request.bodySize>0?g.request.bodySize:0,trafficPie.data[2].value+=g.response.headersSize>0?g.response.headersSize:0,trafficPie.data[3].value+=i,g.response.status==206?(cachePie.data[1].value+=i,cachePie.data[1].count++):g.response.status==304?(cachePie.data[2].value+=i,cachePie.data[2].count++):i>0&&(cachePie.data[0].value+=i,cachePie.data[0].count++)}}Pie.draw(Lib.$(this.timingPie,"pieGraph"),timingPie),Pie.draw(Lib.$(this.contentPie,"pieGraph"),contentPie),Pie.draw(Lib.$(this.trafficPie,"pieGraph"),trafficPie),Pie.draw(Lib.$(this.cachePie,"pieGraph"),cachePie)}},cleanUp:function(){timingPie.cleanUp(),contentPie.cleanUp(),trafficPie.cleanUp(),cachePie.cleanUp()},showInfoTip:function(a,b,c,d){return Pie.showInfoTip(a,b,c,d)},onSelectionChange:function(a){this.update(a)},show:function(a){if(!this.isVisible()){InfoTip.addListener(this),Lib.setClass(this.element,"opened"),!a||$.browser.msie?this.element.style.display="block":$(this.element).slideDown();var b=this.timeline.getSelection();this.update(b)}},hide:function(a){this.isVisible()&&(InfoTip.removeListener(this),Lib.removeClass(this.element,"opened"),!a||$.browser.msie?this.element.style.display="none":$(this.element).slideUp())},isVisible:function(){return Lib.hasClass(this.element,"opened")},toggle:function(a){this.isVisible()?this.hide(a):this.show(a)},render:function(a){this.element=this.tag.replace({},a),this.timingPie=Pie.render(timingPie,this.element),this.contentPie=Pie.render(contentPie,this.element),this.trafficPie=Pie.render(trafficPie,this.element),this.cachePie=Pie.render(cachePie,this.element),this.cachePie.style.borderRight=0;return this.element}});var Pie=domplate({tag:TABLE({"class":"pagePieTable",cellpadding:0,cellspacing:0,_repObject:"$pie"},TBODY(TR(TD({"class":"pieBox",title:"$pie.title"}),TD(FOR("item","$pie.data",DIV({"class":"pieLabel",_repObject:"$item"},SPAN({"class":"box",style:"background-color: $item.color"}," "),SPAN({"class":"label"},"$item.label"))))))),render:function(a,b){var c=this.tag.append({pie:a},b),d=Lib.$(c,"pieBox"),e=document.createElement("canvas");e.setAttribute("class","pieGraph "),e.setAttribute("height","100"),e.setAttribute("width","100"),d.appendChild(e),typeof G_vmlCanvasManager!="undefined"&&G_vmlCanvasManager.initElement(e);return c},draw:function(a,b){if(a&&a.getContext){var c=a.getContext("2d"),d=Math.min(a.width,a.height)/2,e=[a.width/2,a.height/2];c.clearRect(0,0,a.width,a.height);var f=0,g=b.data,h=0;for(var i in g)h+=g[i].value;if(!h){c.beginPath(),c.moveTo(e[0],e[1]),c.arc(e[0],e[1],d,0,Math.PI*2,!1),c.closePath(),c.fillStyle="rgb(229,236,238)",c.lineStyle="lightgray",c.fill();return}for(var i=0;iAbout...

dp.SyntaxHighlighter

Version: {V}

http://www.dreamprojections.com/syntaxhighlighter

©2004-2007 Alex Gorbatchev.
'},ClipboardSwf:null,Version:"1.5.1"}};a.SyntaxHighlighter=a.sh,a.sh.Toolbar.Commands={ExpandSource:{label:"+ expand source",check:function(a){return a.collapse},func:function(a,b){a.parentNode.removeChild(a),b.div.className=b.div.className.replace("collapsed","")}},ViewSource:{label:"view plain",func:function(b,c){var d=a.sh.Utils.FixForBlogger(c.originalCode).replace(/'+d+""),e.document.close()}},CopyToClipboard:{label:"copy to clipboard",check:function(){return window.clipboardData!=null||a.sh.ClipboardSwf!=null},func:function(b,c){var d=a.sh.Utils.FixForBlogger(c.originalCode).replace(/</g,"<").replace(/>/g,">").replace(/&/g,"&");if(window.clipboardData)window.clipboardData.setData("text",d);else if(a.sh.ClipboardSwf!=null){var e=c.flashCopier;e==null&&(e=document.createElement("div"),c.flashCopier=e,c.div.appendChild(e)),e.innerHTML=''}alert("The code is in your clipboard now")}},PrintSource:{label:"print",func:function(b,c){var d=document.createElement("IFRAME"),e=null;d.style.cssText="position:absolute;width:0px;height:0px;left:-500px;top:-500px;",document.body.appendChild(d),e=d.contentWindow.document,a.sh.Utils.CopyStyles(e,window.document),e.write('
'+c.div.innerHTML+"
"),e.close(),d.contentWindow.focus(),d.contentWindow.print(),alert("Printing..."),document.body.removeChild(d)}},About:{label:"?",func:function(b){var c=window.open("","_blank","dialog,width=300,height=150,scrollbars=0"),d=c.document;a.sh.Utils.CopyStyles(d,window.document),d.write(a.sh.Strings.AboutDialog.replace("{V}",a.sh.Version)),d.close(),c.focus()}}},a.sh.Toolbar.Create=function(b){var c=document.createElement("DIV");c.className="tools";for(var d in a.sh.Toolbar.Commands){var e=a.sh.Toolbar.Commands[d];if(e.check!=null&&!e.check(b))continue;c.innerHTML+='"+e.label+""}return c},a.sh.Toolbar.Command=function(b,c){var d=c;while(d!=null&&d.className.indexOf("dp-highlighter")==-1)d=d.parentNode;d!=null&&a.sh.Toolbar.Commands[b].func(c,d.highlighter)},a.sh.Utils.CopyStyles=function(a,b){var c=b.getElementsByTagName("link");for(var d=0;d')},a.sh.Utils.FixForBlogger=function(b){return a.sh.isBloggerMode==!0?b.replace(/|<br\s*\/?>/gi,"\n"):b},a.sh.RegexLib={MultiLineCComments:new RegExp("/\\*[\\s\\S]*?\\*/","gm"),SingleLineCComments:new RegExp("//.*$","gm"),SingleLinePerlComments:new RegExp("#.*$","gm"),DoubleQuotedString:new RegExp('"(?:\\.|(\\\\\\")|[^\\""\\n])*"',"g"),SingleQuotedString:new RegExp("'(?:\\.|(\\\\\\')|[^\\''\\n])*'","g")},a.sh.Match=function(a,b,c){this.value=a,this.index=b,this.length=a.length,this.css=c},a.sh.Highlighter=function(){this.noGutter=!1,this.addControls=!0,this.collapse=!1,this.tabsToSpaces=!0,this.wrapColumn=80,this.showColumns=!0},a.sh.Highlighter.SortCallback=function(a,b){if(a.indexb.index)return 1;if(a.lengthb.length)return 1;return 0},a.sh.Highlighter.prototype.CreateElement=function(a){var b=document.createElement(a);b.highlighter=this;return b},a.sh.Highlighter.prototype.GetMatches=function(b,c){var d=0,e=null;while((e=b.exec(this.code))!=null)this.matches[this.matches.length]=new a.sh.Match(e[0],e.index,c)},a.sh.Highlighter.prototype.AddBit=function(a,b){if(a!=null&&a.length!=0){var c=this.CreateElement("SPAN");a=a.replace(/ /g," "),a=a.replace(/");if(b!=null)if(/br/gi.test(a)){var d=a.split(" 
");for(var e=0;ec.index&&a.index/gi,"\n"),c=b.split("\n");this.addControls==!0&&this.bar.appendChild(a.sh.Toolbar.Create(this));if(this.showColumns){var d=this.CreateElement("div"),e=this.CreateElement("div"),f=10,g=1;while(g<=150)g%f==0?(d.innerHTML+=g,g+=(g+"").length):(d.innerHTML+="·",g++);e.className="columns",e.appendChild(d),this.bar.appendChild(e)}for(var g=0,h=this.firstLine;g0;h++){if(c(d[h]).length==0)continue;var i=f.exec(d[h]);i!=null&&i.length>0&&(g=Math.min(i[0].length,g))}if(g>0)for(var h=0;h0&&c.appendTab(new HeadersTab(b)),b.request.queryString&&b.request.queryString.length&&c.appendTab(new ParamsTab(b)),b.request.postData&&c.appendTab(new SentDataTab(b,b.request.method)),b.response.content.text&&b.response.content.text.length>0&&c.appendTab(new ResponseTab(b)),this.showCache(b)&&c.appendTab(new CacheTab(b)),this.showHtml(b)&&c.appendTab(new HtmlTab(b)),this.showDataURL(b)&&c.appendTab(new DataURLTab(b));var d=c.render(a);c.tabs.length>0&&c.selectTabByName(c.tabs[0].id);return d},showCache:function(a){if(!a.cache)return!1;if(!a.cache.afterRequest)return!1;if(a.category=="image")return!1;return!0},showHtml:function(a){return a.response.content.mimeType=="text/html"||a.mimeType=="application/xhtml+xml"},showDataURL:function(a){return a.request.url.indexOf("data:")==0}});function HeadersTab(a){this.file=a}HeadersTab.prototype=domplate(TabView.Tab.prototype,{id:"Headers",label:Strings.Headers,bodyTag:TABLE({"class":"netInfoHeadersText netInfoText netInfoHeadersTable",cellpadding:0,cellspacing:0},TBODY(TR({"class":"netInfoResponseHeadersTitle"},TD({colspan:2},DIV({"class":"netInfoHeadersGroup"},Strings.ResponseHeaders))),TR({"class":"netInfoRequestHeadersTitle"},TD({colspan:2},DIV({"class":"netInfoHeadersGroup"},Strings.RequestHeaders))))),headerDataTag:FOR("param","$headers",TR(TD({"class":"netInfoParamName"},"$param.name"),TD({"class":"netInfoParamValue"},PRE("$param|getParamValue")))),getParamValue:function(a){return Lib.wrapText(a.value,!0)},onUpdateBody:function(a,b){this.file.response.headers&&this.insertHeaderRows(b,this.file.response.headers,"Headers","ResponseHeaders"),this.file.request.headers&&this.insertHeaderRows(b,this.file.request.headers,"Headers","RequestHeaders")},insertHeaderRows:function(a,b,c,d){var e=Lib.getElementByClass(a,"netInfo"+c+"Table"),f=Lib.getElementByClass(e,"netInfo"+d+"Title");b.length?(this.headerDataTag.insertRows({headers:b},f?f:a),Lib.removeClass(f,"collapsed")):Lib.setClass(f,"collapsed")}});function ResponseTab(a){this.file=a}ResponseTab.prototype=domplate(TabView.Tab.prototype,{id:"Response",label:Strings.Response,bodyTag:DIV({"class":"netInfoResponseText netInfoText"},PRE({"class":"javascript:nocontrols:nogutter:",name:"code"})),onUpdateBody:function(a,b){var c=Lib.getElementByClass(b,"netInfoResponseText");if(this.file.category=="image"){Lib.clearNode(c);var d=b.ownerDocument.createElement("img");d.src=this.file.href,c.appendChild(d,c)}else{Lib.clearNode(c.firstChild);var e=this.file.response.content.text,f=this.file.response.content.mimeType;f=="application/javascript"||f=="text/javascript"||f=="application/x-javascript"||f=="text/ecmascript"||f=="application/ecmascript"?(c.firstChild.innerHTML=e,dp.SyntaxHighlighter.HighlightAll(c.firstChild)):Lib.insertWrappedText(e,c.firstChild)}}});function ParamsTab(a){this.file=a}ParamsTab.prototype=domplate(HeadersTab.prototype,{id:"Params",label:Strings.URLParameters,bodyTag:TABLE({"class":"netInfoParamsText netInfoText netInfoParamsTable",cellpadding:0,cellspacing:0},TBODY()),onUpdateBody:function(a,b){if(this.file.request.queryString){var c=Lib.getElementByClass(b,"netInfoParamsText");this.insertHeaderRows(c,this.file.request.queryString,"Params")}}});function SentDataTab(a,b){b=b.charAt(0).toUpperCase()+b.slice(1).toLowerCase(),this.file=a,this.id=b,this.label=Strings[b]}SentDataTab.prototype=domplate(HeadersTab.prototype,{bodyTag:DIV({"class":"netInfo$tab.id\\Text netInfoText"},TABLE({"class":"netInfo$tab.id\\Table",cellpadding:0,cellspacing:0},TBODY())),onUpdateBody:function(a,b){var c=this.file.request.postData;if(c){var d=Lib.getElementByClass(b,"netInfo"+this.id+"Text");c.mimeType=="application/x-www-form-urlencoded"?this.insertHeaderRows(d,c.params,this.id):Lib.insertWrappedText(c.text,d)}}});function CookiesTab(a){this.file=a}CookiesTab.prototype=domplate(HeadersTab.prototype,{id:"Cookies",label:Strings.Cookies,bodyTag:DIV({"class":"netInfoCookiesText netInfoText"},TABLE({"class":"netInfoCookiesTable",cellpadding:0,cellspacing:0},TBODY(TR({"class":"netInfoResponseCookiesTitle"},TD({colspan:2},DIV({"class":"netInfoCookiesGroup"},Strings.ResponseCookies))),TR({"class":"netInfoRequestCookiesTitle"},TD({colspan:2},DIV({"class":"netInfoCookiesGroup"},Strings.RequestCookies)))))),onUpdateBody:function(a,b){if(file.response.cookies){var c=Lib.getElementByClass(b,"netInfoParamsText");this.insertHeaderRows(c,file.response.cookies,"Cookies","ResponseCookies")}if(file.request.cookies){var c=Lib.getElementByClass(b,"netInfoParamsText");this.insertHeaderRows(c,file.request.cookies,"Cookies","RequestCookies")}}});function CacheTab(a){this.file=a}CacheTab.prototype=domplate(HeadersTab.prototype,{id:"Cache",label:Strings.Cache,bodyTag:DIV({"class":"netInfoCacheText netInfoText"},TABLE({"class":"netInfoCacheTable",cellpadding:0,cellspacing:0},TBODY())),onUpdateBody:function(a,b){if(this.file.cache&&this.file.cache.afterRequest){var c=this.file.cache.afterRequest,d=[];for(var e in c)d.push({name:e,value:c[e]});this.insertHeaderRows(b,d,"Cache")}}});function HtmlTab(a){this.file=a}HtmlTab.prototype=domplate(HeadersTab.prototype,{id:"HTML",label:Strings.HTML,bodyTag:DIV({"class":"netInfoHtmlText netInfoText"},IFRAME({"class":"netInfoHtmlPreview",onload:"$onLoad"}),DIV({"class":"htmlPreviewResizer"})),onUpdateBody:function(a,b){this.preview=Lib.getElementByClass(b,"netInfoHtmlPreview");var c=parseInt(Cookies.getCookie("htmlPreviewHeight"));isNaN(c)||(this.preview.style.height=c+"px");var d=Lib.getElementByClass(b,"htmlPreviewResizer");this.resizer=new DragDrop.Tracker(d,{onDragStart:Lib.bind(this.onDragStart,this),onDragOver:Lib.bind(this.onDragOver,this),onDrop:Lib.bind(this.onDrop,this)})},onLoad:function(a){var b=Lib.fixEvent(a),c=Lib.getAncestorByClass(b.target,"tabHTMLBody").repObject;c.preview.contentWindow.document.body.innerHTML=c.file.response.content.text},onDragStart:function(a){var b=Lib.getBody(this.preview.ownerDocument);b.setAttribute("hResizing","true"),this.startHeight=this.preview.clientHeight},onDragOver:function(a,b){var c=this.startHeight+a.y;this.preview.style.height=c+"px",Cookies.setCookie("htmlPreviewHeight",c)},onDrop:function(a){var b=Lib.getBody(this.preview.ownerDocument);b.removeAttribute("hResizing")}});function DataURLTab(a){this.file=a}DataURLTab.prototype=domplate(HeadersTab.prototype,{id:"DataURL",label:Strings.DataURL,bodyTag:DIV({"class":"netInfoDataURLText netInfoText"}),onUpdateBody:function(a,b){var c=Lib.getElementByClass(b,"netInfoDataURLText"),d=this.file.request.url;if(d.indexOf("data:image")==0){var e=b.ownerDocument.createElement("img");e.src=d,c.appendChild(e)}else Lib.insertWrappedText(unescape(d),c)}});return RequestBody}}),require.def("preview/requestList",["domplate/domplate","core/lib","i18n!nls/requestList","preview/harModel","core/cookies","preview/requestBody","domplate/infoTip","domplate/popupMenu"],function(Domplate,Lib,Strings,HarModel,Cookies,RequestBody,InfoTip,Menu){with(Domplate){function RequestList(a){this.input=a,this.pageTimings=[],this.addPageTiming({name:"onContentLoad",classes:"netContentLoadBar",description:Strings.ContentLoad}),this.addPageTiming({name:"onLoad",classes:"netWindowLoadBar",description:Strings.WindowLoad}),InfoTip.addListener(this)}RequestList.columns=["url","status","type","domain","size","timeline"],RequestList.defaultColumns=["url","status","size","timeline"],RequestList.getVisibleColumns=function(){var a=Cookies.getCookie("previewCols");if(a){a=a.replace(/\+/g," "),a=unescape(a);return a.split(" ")}if(!a){var b=document.getElementById("content");if(b){a=b.getAttribute("previewCols");if(a)return a.split(" ")}}return Lib.cloneArray(RequestList.defaultColumns)},RequestList.setVisibleColumns=function(a,b){a||(a=RequestList.getVisibleColumns()),a.join&&(a=a.join(" "));var c=document.getElementById("content");c&&c.setAttribute("previewCols",a),b||Cookies.setCookie("previewCols",a)},RequestList.setVisibleColumns(),RequestList.prototype=domplate({tableTag:TABLE({"class":"netTable",cellpadding:0,cellspacing:0,onclick:"$onClick",_repObject:"$requestList"},TBODY(TR({"class":"netSizerRow"},TD({"class":"netHrefCol netCol",width:"20%"}),TD({"class":"netStatusCol netCol",width:"7%"}),TD({"class":"netTypeCol netCol",width:"7%"}),TD({"class":"netDomainCol netCol",width:"7%"}),TD({"class":"netSizeCol netCol",width:"7%"}),TD({"class":"netTimeCol netCol",width:"100%"}),TD({"class":"netOptionsCol netCol",width:"15px"})))),fileTag:FOR("file","$files",TR({"class":"netRow loaded",$isExpandable:"$file|isExpandable",$responseError:"$file|isError",$responseRedirect:"$file|isRedirect",$fromCache:"$file|isFromCache"},TD({"class":"netHrefCol netCol"},DIV({"class":"netHrefLabel netLabel",style:"margin-left: $file|getIndent\\px"},"$file|getHref"),DIV({"class":"netFullHrefLabel netHrefLabel netLabel",style:"margin-left: $file|getIndent\\px"},"$file|getFullHref")),TD({"class":"netStatusCol netCol"},DIV({"class":"netStatusLabel netLabel"},"$file|getStatus")),TD({"class":"netTypeCol netCol"},DIV({"class":"netTypeLabel netLabel"},"$file|getType")),TD({"class":"netDomainCol netCol"},DIV({"class":"netDomainLabel netLabel"},"$file|getDomain")),TD({"class":"netSizeCol netCol"},DIV({"class":"netSizeLabel netLabel"},"$file|getSize")),TD({"class":"netTimeCol netCol"},DIV({"class":"netTimelineBar"}," ",DIV({"class":"netBlockingBar netBar"}),DIV({"class":"netResolvingBar netBar"}),DIV({"class":"netConnectingBar netBar"}),DIV({"class":"netSendingBar netBar"}),DIV({"class":"netWaitingBar netBar"}),DIV({"class":"netReceivingBar netBar"},SPAN({"class":"netTimeLabel"},"$file|getElapsedTime")))),TD({"class":"netOptionsCol netCol"},DIV({"class":"netOptionsLabel netLabel",onclick:"$onOpenOptions"})))),headTag:TR({"class":"netHeadRow"},TD({"class":"netHeadCol",colspan:7},DIV({"class":"netHeadLabel"},"$doc.rootFile.href"))),netInfoTag:TR({"class":"netInfoRow"},TD({"class":"netInfoCol",colspan:7})),summaryTag:TR({"class":"netRow netSummaryRow"},TD({"class":"netHrefCol netCol"},DIV({"class":"netCountLabel netSummaryLabel"},"-")),TD({"class":"netStatusCol netCol"}),TD({"class":"netTypeCol netCol"}),TD({"class":"netDomainCol netCol"}),TD({"class":"netTotalSizeCol netSizeCol netCol"},DIV({"class":"netTotalSizeLabel netSummaryLabel"},"0KB")),TD({"class":"netTotalTimeCol netTimeCol netCol"},DIV({"class":"",style:"width: 100%"},DIV({"class":"netCacheSizeLabel netSummaryLabel"},"(",SPAN("0KB"),SPAN(" "+Strings.fromCache),")"),DIV({"class":"netTimeBar"},SPAN({"class":"netTotalTimeLabel netSummaryLabel"},"0ms")))),TD({"class":"netOptionsCol netCol"})),getIndent:function(a){return 0},isError:function(a){var b=Math.floor(a.response.status/100);return b==4||b==5},isRedirect:function(a){return!1},isFromCache:function(a){return a.cache&&a.cache.afterRequest},getHref:function(a){var b=Lib.getFileName(this.getFullHref(a));return unescape(a.request.method+" "+b)},getFullHref:function(a){return unescape(a.request.url)},getStatus:function(a){var b=a.response.status>0?a.response.status+" ":"";return b+a.response.statusText},getType:function(a){return a.response.content.mimeType},getDomain:function(a){return Lib.getPrettyDomain(a.request.url)},getSize:function(a){var b=a.response.bodySize,c=b&&b!=-1?b:a.response.content.size;return this.formatSize(c)},isExpandable:function(a){var b=a.response.headers.length>0,c=a.request.url.indexOf("data:")==0;return b||c},formatSize:function(a){return Lib.formatSize(a)},getElapsedTime:function(a){var b=Math.round(a.time*10)/10;return Lib.formatTime(b)},onClick:function(a){var b=Lib.fixEvent(a);if(Lib.isLeftClick(a)){var c=Lib.getAncestorByClass(b.target,"netRow");c&&(this.toggleHeadersRow(c),Lib.cancelEvent(a))}else Lib.isControlClick(a)&&window.open(a.target.innerText||a.target.textContent)},toggleHeadersRow:function(a){if(Lib.hasClass(a,"isExpandable")){var b=a.repObject;Lib.toggleClass(a,"opened");if(Lib.hasClass(a,"opened")){var c=this.netInfoTag.insertRows({},a)[0];c.repObject=b;var d=new RequestBody;d.render(c.firstChild,b)}else{var c=a.nextSibling,e=Lib.getElementByClass(c,"netInfoBody");a.parentNode.removeChild(c)}}},onOpenOptions:function(a){var b=Lib.fixEvent(a);Lib.cancelEvent(a);if(Lib.isLeftClick(a)){var c=b.target,d=Lib.getAncestorByClass(c,"netRow"),e=this.getMenuItems(d);if(!e.length)return;var f=new Menu({id:"requestContextMenu",items:e});f.showPopup(c)}},getMenuItems:function(a){var b=a.repObject,c=a.phase,d=c.files[0]==b&&this.phases[0]==c,e=[{label:Strings.menuBreakTimeline,type:"checkbox",disabled:d,checked:c.files[0]==b&&!d,command:Lib.bind(this.breakLayout,this,a)},"-",{label:Strings.menuOpenRequest,command:Lib.bind(this.openRequest,this,b)},{label:Strings.menuOpenResponse,disabled:!b.response.content.text,command:Lib.bind(this.openResponse,this,b)}];Lib.dispatch(this.listeners,"getMenuItems",[e,this.input,b]);return e},openRequest:function(a,b){window.open(b.request.url)},openResponse:function(a,b){var c=b.response.content.text,d=b.response.content.mimeType,e=b.response.content.encoding,f="data:"+(d?d:"")+";"+(e?e:"")+","+c;window.open(f)},breakLayout:function(a,b){var c=b.repObject,d=b.phase,e=d.files[0]==c;b.breakLayout=!e,b.setAttribute("breakLayout",b.breakLayout?"true":"false");var f=Lib.getAncestorByClass(b,"netTable"),g=HarModel.getParentPage(this.input,c);this.updateLayout(f,g)},updateLayout:function(a,b){var c=HarModel.getPageEntries(this.input,b);this.table=a;var d=this.table.firstChild,e=this.firstRow=d.firstChild.nextSibling;this.phases=[];var f=Cookies.getCookie("phaseInterval");f||(f=4e3);var g=null,h=b?Lib.parseISO8601(b.startedDateTime):null,i=b&&b.pageTimings?b.pageTimings.onLoad:-1;i>0&&(i+=h);for(var j=0;j=0&&(o=l>i&&l-m>=f&&l+k.time>=n+f),typeof e.breakLayout=="boolean"?!g||e.breakLayout?g=this.startPhase(k):g.addFile(k):!g||o?g=this.startPhase(k):g.addFile(k),this.phases[0]!=g&&e.setAttribute("breakLayout",g.files[0]==k?"true":"false");if(g.startTime==undefined||g.startTime>l)g.startTime=l;if(g.endTime==undefined||g.endTime0){var g=d+f-c.startTime,h=(g/this.phaseElapsed*100).toFixed(3);c.pageTimings[e].offset=h}}}},updateTimeline:function(a){var b=this.table.firstChild,c;for(var d=this.firstRow;d;d=d.nextSibling){var e=d.repObject;if(!e)continue;if(Lib.hasClass(d,"netInfoRow"))continue;c=this.calculateFileTimes(a,e,c),d.phase=e.phase,delete e.phase;var f=Lib.getElementByClass(d,"netTimelineBar"),g=f.children[0],h=g.nextSibling,i=h.nextSibling,j=i.nextSibling,k=j.nextSibling,l=k.nextSibling;g.style.left=i.style.left=h.style.left=j.style.left=k.style.left=l.style.left=this.barOffset+"%",g.style.width=this.barBlockingWidth+"%",h.style.width=this.barResolvingWidth+"%",i.style.width=this.barConnectingWidth+"%",j.style.width=this.barSendingWidth+"%",k.style.width=this.barWaitingWidth+"%",l.style.width=this.barReceivingWidth+"%";var m=Lib.getElementsByClass(f,"netPageTimingBar");for(var n=0;n0&&b.push({label:d.name,time:e,classes:d.classes,comment:d.description})}var f=a.pageTimings?a.pageTimings._timeStamps:[];f&&b.push.apply(b,f);var g=this.phases;for(var c=0;c=h.startTime)h.startTime>l&&(h.startTime=l),h.endTime0&&(o+=" (onload: "+Lib.formatTime(a.pageTimings.onLoad)+")"),n.innerHTML=o}},formatRequestCount:function(a){return a+" "+(a==1?Strings.request:Strings.requests)},summarizePhase:function(a){var b=0,c=0,d="all";d=="all"&&(d=null);var e=0,f=0,g=0;for(var h=0;hg&&(g=m)}}var n=g-f;return{cachedSize:b,totalSize:c,totalTime:n,fileCount:e}},showInfoTip:function(a,b,c,d){var e=Lib.getAncestorByClass(b,"netTable");if(e&&e.repObject==this){var f=Lib.getAncestorByClass(b,"netRow");if(f){if(Lib.getAncestorByClass(b,"netBar")){a.setAttribute("multiline",!0);var g=f.repObject.startedDateTime+"-nettime";this.infoTipURL=g;return this.populateTimeInfoTip(a,f)}if(Lib.hasClass(b,"netSizeLabel")){var g=f.repObject.startedDateTime+"-netsize";this.infoTipURL=g;return this.populateSizeInfoTip(a,f)}}}},populateTimeInfoTip:function(a,b){EntryTimeInfoTip.render(this,b,a);return!0},populateSizeInfoTip:function(a,b){EntrySizeInfoTip.render(this,b,a);return!0},render:function(a,b){var c=HarModel.getPageEntries(this.input,b);if(!c.length)return null;return this.append(a,b,c)},append:function(a,b,c){this.table||(this.table=this.tableTag.replace({requestList:this},a,this)),this.summaryRow||(this.summaryRow=this.summaryTag.insertRows({},this.table.firstChild)[0]);var d=this.table.firstChild,e=d.lastChild.previousSibling,f=this.fileTag.insertRows({files:c},e,this);this.updateLayout(this.table,b);return f[0]},addPageTiming:function(a){this.pageTimings.push(a)}});function Phase(a){this.files=[],this.pageTimings=[],this.addFile(a)}Phase.prototype={addFile:function(a){this.files.push(a),a.phase=this},getLastStartTime:function(){return this.files[this.files.length-1].startedDateTime}};var EntryTimeInfoTip=domplate({tableTag:TABLE({"class":"timeInfoTip"},TBODY()),timingsTag:FOR("time","$timings",TR({"class":"timeInfoTipRow",$collapsed:"$time|hideBar"},TD({"class":"$time|getBarClass timeInfoTipBar",$loaded:"$time.loaded",$fromCache:"$time.fromCache"}),TD({"class":"timeInfoTipCell startTime"},"$time.start|formatStartTime"),TD({"class":"timeInfoTipCell elapsedTime"},"$time.elapsed|formatTime"),TD("$time|getLabel"))),startTimeTag:TR(TD(),TD("$startTime.time|formatStartTime"),TD({"class":"timeInfoTipStartLabel",colspan:2},"$startTime|getLabel")),separatorTag:TR({},TD({"class":"timeInfoTipSeparator",colspan:4,height:"10px"},SPAN("$label"))),eventsTag:FOR("event","$events",TR({"class":"timeInfoTipEventRow"},TD({"class":"timeInfoTipBar",align:"center"},DIV({"class":"$event|getPageTimingClass timeInfoTipEventBar"})),TD("$event.start|formatStartTime"),TD({colspan:2},"$event|getTimingLabel"))),hideBar:function(a){return!a.elapsed&&a.bar=="request.phase.Blocking"},getBarClass:function(a){var b=a.bar.substr(a.bar.lastIndexOf(".")+1);return"net"+b+"Bar"},getPageTimingClass:function(a){return a.classes?a.classes:""},formatTime:function(a){return Lib.formatTime(a)},formatStartTime:function(a){var b=a>0,c=Lib.formatTime(Math.abs(a));if(!a)return c;return(b>0?"+":"-")+c},getLabel:function(a){return Strings[a.bar]},getTimingLabel:function(a){return a.bar},render:function(a,b,c){var d=a.input,e=b.repObject,f=HarModel.getParentPage(d,e),g=f?Lib.parseISO8601(f.startedDateTime):null,h=Lib.parseISO8601(e.startedDateTime),i=EntryTimeInfoTip.tableTag.replace({},c),j={};g?j.time=h-g:j.time=h-b.phase.startTime,j.bar="request.Started",this.startTimeTag.insertRows({startTime:j},i.firstChild),this.separatorTag.insertRows({label:Strings["request.phases.label"]},i.firstChild);var k=0,l=[],m=e.timings.blocked,n=e.timings.dns,o=e.timings.ssl,p=e.timings.connect,q=e.timings.send,r=e.timings.wait,s=e.timings.receive;m>=0&&l.push({bar:"request.phase.Blocking",elapsed:m,start:k}),n>=0&&l.push({bar:"request.phase.Resolving",elapsed:n,start:k+=m<0?0:m}),p>=0&&l.push({bar:"request.phase.Connecting",elapsed:p,start:k+=n<0?0:n}),q>=0&&l.push({bar:"request.phase.Sending",elapsed:q,start:k+=p<0?0:p}),r>=0&&l.push({bar:"request.phase.Waiting",elapsed:r,start:k+=q<0?0:q}),s>=0&&l.push({bar:"request.phase.Receiving",elapsed:s,start:k+=r<0?0:r,loaded:e.loaded,fromCache:e.fromCache}),this.timingsTag.insertRows({timings:l},i.firstChild);if(!f)return!0;var t=[];for(var u=0;u-1;e.push({label:Strings["column.label."+g],type:"checkbox",checked:h,command:Lib.bindFixed(this.onToggleColumn,this,g)}),h&&(c=f,d++)}d==1&&(e[c].disabled=!0),e.push("-"),e.push({label:Strings["action.label.Reset"],command:Lib.bindFixed(this.updateColumns,this)});return e},onToggleColumn:function(a){var b=RequestList.getVisibleColumns();Lib.remove(b,a)||b.push(a),this.updateColumns(b)},updateColumns:function(a){a||(a=RequestList.defaultColumns),RequestList.setVisibleColumns(a)},createRequestList:function(){var a=new RequestList(this.input);a.listeners=this.listeners;return a},append:function(a){var b=this.createRequestList();b.render(a,null);var c=this.input.log.pages;if(c&&c.length){var d=this.tableTag.append({input:this.input},a,this),e=Lib.getElementsByClass(d,"pageRow"),f=Lib.getElementsByClass(a,"pageTable");e.length==1&&f.length==1&&this.toggleRow(e[0]);var g=Lib.getURLParameter("expand");g&&this.expandAll(d)}},render:function(a){this.append(a)},addListener:function(a){this.listeners.push(a)},removeListener:function(a){Lib.remove(this.listeners,a)}}),PageList.prototype.pageTimings=[];return PageList}}),require.def("preview/validationError",["domplate/domplate","core/lib","core/trace","domplate/popupMenu"],function(Domplate,Lib,Trace,Menu){with(Domplate){var ValidationError=domplate({errorTable:TABLE({"class":"errorTable",cellpadding:3,cellspacing:0},TBODY(FOR("error","$errors",TR({"class":"errorRow",_repObject:"$error"},TD({"class":"errorProperty"},SPAN("$error.property")),TD({"class":"errorOptions",$hasTarget:"$error|hasTarget"},DIV({"class":"errorOptionsTarget",onclick:"$onOpenOptions"}," ")),TD(" "),TD({"class":"errorMessage"},SPAN("$error.message")))))),hasTarget:function(a){return a.input&&a.file},onOpenOptions:function(a){var b=Lib.fixEvent(a);Lib.cancelEvent(a);if(Lib.isLeftClick(a)){var c=b.target,d=Lib.getAncestorByClass(c,"errorRow"),e=d.repObject;if(!e||!e.input||!e.file)return;var f=this.getMenuItems(e.input,e.file);if(!f.length)return;var g=new Menu({id:"requestContextMenu",items:f});g.showPopup(c)}},getMenuItems:function(a,b){var c=[];Lib.dispatch(this.listeners,"getMenuItems",[c,a,b]);return c},listeners:[],addListener:function(a){this.listeners.push(a)},removeListener:function(a){Lib.remove(this.listeners,a)},appendError:function(a,b){a.errors&&this.errorTable.append(a,b)}});return ValidationError}});var swfobject=function(){function O(a){var b=/[\\\"<>\.;]/,c=b.exec(a)!=null;return c?encodeURIComponent(a):a}function N(a,b){var c=b?"visible":"hidden";r&&I(a)?I(a).style.visibility=c:M("#"+a,"visibility:"+c)}function M(c,d){if(!t.ie||!t.mac){var e=h.getElementsByTagName("head")[0],f=J("style");f.setAttribute("type","text/css"),f.setAttribute("media","screen"),(!t.ie||!t.win)&&typeof h.createTextNode!=a&&f.appendChild(h.createTextNode(c+" {"+d+"}")),e.appendChild(f);if(t.ie&&t.win&&typeof h.styleSheets!=a&&h.styleSheets.length>0){var g=h.styleSheets[h.styleSheets.length-1];typeof g.addRule==b&&g.addRule(c,d)}}}function L(a){var b=t.pv,c=a.split(".");c[0]=parseInt(c[0],10),c[1]=parseInt(c[1],10)||0,c[2]=parseInt(c[2],10)||0;return b[0]>c[0]||b[0]==c[0]&&b[1]>c[1]||b[0]==c[0]&&b[1]==c[1]&&b[2]>=c[2]?!0:!1}function K(a,b,c){a.attachEvent(b,c),m[m.length]=[a,b,c]}function J(a){return h.createElement(a)}function I(a){var b=null;try{b=h.getElementById(a)}catch(c){}return b}function H(a){var b=I(a);if(b){for(var c in b)typeof b[c]=="function"&&(b[c]=null);b.parentNode.removeChild(b)}}function G(a){var b=I(a);b&&(b.nodeName=="OBJECT"||b.nodeName=="EMBED")&&(t.ie&&t.win?b.readyState==4?H(a):g.attachEvent("onload",function(){H(a)}):b.parentNode.removeChild(b))}function F(a,b,c){var d=J("param");d.setAttribute("name",b),d.setAttribute("value",c),a.appendChild(d)}function E(c,d,f){var g,h=I(f);if(h){typeof c.id==a&&(c.id=f);if(t.ie&&t.win){var i="";for(var j in c)c[j]!=Object.prototype[j]&&(j.toLowerCase()=="data"?d.movie=c[j]:j.toLowerCase()=="styleclass"?i+=' class="'+c[j]+'"':j.toLowerCase()!="classid"&&(i+=" "+j+'="'+c[j]+'"'));var k="";for(var m in d)d[m]!=Object.prototype[m]&&(k+='');h.outerHTML='"+k+"",l[l.length]=c.id,g=I(c.id)}else if(t.webkit&&t.webkit<312){var n=J("embed");n.setAttribute("type",e);for(var o in c)c[o]!=Object.prototype[o]&&(o.toLowerCase()=="data"?n.setAttribute("src",c[o]):o.toLowerCase()=="styleclass"?n.setAttribute("class",c[o]):o.toLowerCase()!="classid"&&n.setAttribute(o,c[o]));for(var p in d)d[p]!=Object.prototype[p]&&(p.toLowerCase()!="movie"&&n.setAttribute(p,d[p]));h.parentNode.replaceChild(n,h),g=n}else{var q=J(b);q.setAttribute("type",e);for(var r in c)c[r]!=Object.prototype[r]&&(r.toLowerCase()=="styleclass"?q.setAttribute("class",c[r]):r.toLowerCase()!="classid"&&q.setAttribute(r,c[r]));for(var s in d)d[s]!=Object.prototype[s]&&s.toLowerCase()!="movie"&&F(q,s,d[s]);h.parentNode.replaceChild(q,h),g=q}}return g}function D(a){var c=J("div");if(t.win&&t.ie)c.innerHTML=a.innerHTML;else{var d=a.getElementsByTagName(b)[0];if(d){var e=d.childNodes;if(e){var f=e.length;for(var g=0;g0){var d=I(c);d&&(k[b].width=d.getAttribute("width")?d.getAttribute("width"):"0",k[b].height=d.getAttribute("height")?d.getAttribute("height"):"0",L(k[b].swfVersion)?(t.webkit&&t.webkit<312&&A(d),N(c,!0)):k[b].expressInstall&&!s&&L("6.0.65")&&(t.win||t.mac)?B(k[b]):C(d))}else N(c,!0)}}function y(b){if(typeof g.addEventListener!=a)g.addEventListener("load",b,!1);else if(typeof h.addEventListener!=a)h.addEventListener("load",b,!1);else if(typeof g.attachEvent!=a)K(g,"onload",b);else if(typeof g.onload=="function"){var c=g.onload;g.onload=function(){c(),b()}}else g.onload=b}function x(a){r?a():j[j.length]=a}function w(){if(!r){if(t.ie&&t.win){var a=J("span");try{var b=h.getElementsByTagName("body")[0].appendChild(a);b.parentNode.removeChild(b)}catch(c){return}}r=!0,o&&(clearInterval(o),o=null);var d=j.length;for(var e=0;e"),n=I("__ie_ondomload"),n&&K(n,"onreadystatechange",v)}catch(b){}t.webkit&&typeof h.readyState!=a&&(o=setInterval(function(){/loaded|complete/.test(h.readyState)&&w()},10)),typeof h.addEventListener!=a&&h.addEventListener("DOMContentLoaded",w,null),y(w)}}(),P=function(){t.ie&&t.win&&window.attachEvent("onunload",function(){var a=m.length;for(var b=0;b0){var b=this.getCurrentScope(),c=this.find(b);if(c)return c}return!1},find:function(a){var b=0;for(var c in a.object){b++;if(a.propIndex>=b)continue;var d=a.object[c];if(!d)continue;a.propIndex=b;if(typeof d=="object"){this.stack.push({propIndex:0,object:d,startOffset:-1});return!1}var e=this.text,f=d+"";Cookies.getBooleanCookie(caseSensitiveOption)||(f=f.toLowerCase(),e=e.toLowerCase());var g=a.startOffset<0?0:a.startOffset,h=f.indexOf(e,g);if(h>=0){a.propIndex+=-1,a.startOffset=h+e.length,this.matches.push({value:d,startOffset:h});return!0}}this.stack.pop();return!1},getCurrentScope:function(){return this.stack[this.stack.length-1]},getCurrentMatch:function(){return this.matches[this.matches.length-1]},selectText:function(a){var b=this.getCurrentMatch();Lib.selectElementText(a,b.startOffset,b.startOffset+this.text.length)}},Search.Resizer=domplate({initialize:function(a,b){this.searchInput=a,this.tracker=new DragDrop.Tracker(b,{onDragStart:Lib.bind(this.onDragStart,this),onDragOver:Lib.bind(this.onDragOver,this),onDrop:Lib.bind(this.onDrop,this)})},onDragStart:function(a){var b=Lib.getBody(this.searchInput.ownerDocument);b.setAttribute("vResizing","true"),this.startWidth=this.searchInput.clientWidth-20},onDragOver:function(a,b){var c=this.startWidth-a.x,d=Lib.getAncestorByClass(this.searchInput,"toolbar");c<=d.clientWidth-40&&(this.searchInput.style.width=c+"px")},onDrop:function(a){var b=Lib.getBody(this.searchInput.ownerDocument);b.removeAttribute("vResizing")}});return Search}}),require.def("domplate/domTree",["domplate/domplate","core/lib","core/trace"],function(Domplate,Lib,Trace){with(Domplate){function DomTree(a){this.input=a}DomTree.prototype=domplate({tag:TABLE({"class":"domTable",cellpadding:0,cellspacing:0,onclick:"$onClick"},TBODY(FOR("member","$object|memberIterator",TAG("$member|getRowTag",{member:"$member"})))),rowTag:TR({"class":"memberRow $member.open $member.type\\Row $member|hasChildren",$hasChildren:"$member|hasChildren",_repObject:"$member",level:"$member.level"},TD({"class":"memberLabelCell",style:"padding-left: $member.indent\\px"},SPAN({"class":"memberLabel $member.type\\Label"},"$member.name")),TD({"class":"memberValueCell"},TAG("$member.tag",{object:"$member|getValue"}))),loop:FOR("member","$members",TAG("$member|getRowTag",{member:"$member"})),hasChildren:function(a){return a.hasChildren?"hasChildren":""},memberIterator:function(a){return this.getMembers(a)},getValue:function(a){return a.value},getRowTag:function(a){return this.rowTag},onClick:function(a){var b=Lib.fixEvent(a);if(Lib.isLeftClick(b)){var c=Lib.getAncestorByClass(b.target,"memberRow"),d=Lib.getAncestorByClass(b.target,"memberLabel");d&&Lib.hasClass(c,"hasChildren")&&this.toggleRow(c)}},toggleRow:function(a,b){if(a){var c=parseInt(a.getAttribute("level"));if(b&&Lib.hasClass(a,"opened"))return;if(Lib.hasClass(a,"opened")){Lib.removeClass(a,"opened");var d=a.parentNode;for(var e=a.nextSibling;e;e=a.nextSibling){if(parseInt(e.getAttribute("level"))<=c)break;d.removeChild(e)}}else{Lib.setClass(a,"opened");var f=a.repObject;if(f){if(!f.hasChildren)return;var g=this.getMembers(f.value,c+1);g&&this.loop.insertRows({members:g},a)}}}},getMembers:function(a,b){b||(b=0);var c=[];for(var d in a){var e=a[d];typeof e!="function"&&c.push(this.createMember("dom",d,e,b))}return c},createMember:function(a,b,c,d){var e=typeof c,f=this.hasProperties(c)&&e=="object",g=DomTree.Reps.getRep(c);return{name:b,value:c,type:a,rowClass:"memberRow-"+a,open:"",level:d,indent:d*16,hasChildren:f,tag:g.tag}},hasProperties:function(a){if(typeof a=="string")return!1;try{for(var b in a)return!0}catch(c){}return!1},append:function(a){this.element=this.tag.append({object:this.input},a),this.element.repObject=this;var b=Lib.isArray(this.input)&&this.input.length>2,c=this.element.firstChild.firstChild;c&&!b&&this.toggleRow(c)},expandRow:function(a){var b=this.getRow(a);this.toggleRow(b,!0);return b},getRow:function(a){if(this.element){var b=Lib.getElementsByClass(this.element,"memberRow");for(var c=0;c=0;--m)d.appendChild(f[m].row)}else{Lib.removeClass(l,"sortedDescending"),Lib.setClass(l,"sortedAscending"),l.setAttribute("aria-sort","ascending"),l.sorted=-1;for(var m=0;m0&&k.clientHeight>l&&(k.style.height=l+"px")}catch(m){Trace.exception("tableView.render; EXCEPTION "+m,m)}finally{delete this.columns}}}});return TableView}}),function(){function distinctFilter(a,b){var c=[],d={};for(var e=0,f=a.length;e0?"`]":a.charAt(0)=='"'||a.charAt(0)=="'"?"`"+(str.push(a)-1):a});var prefix="";query.replace(/(\]|\)|push|pop|shift|splice|sort|reverse)\s*\(/,function(){throw new Error("Unsafe function call")}),query=query.replace(/([^=]=)([^=])/g,"$1=$2").replace(/@|(\.\s*)?[a-zA-Z\$_]+(\s*:)?/g,function(a){return a.charAt(0)=="."?a:a=="@"?"$obj":(a.match(/:|^(\$|Math|true|false|null)$/)?"":"$obj.")+a}).replace(/\.?\.?\[(`\]|[^\]])*\]|\?.*|\.\.([\w\$_]+)|\.\*/g,function(a,b,c){var d=a.match(/^\.?\.?(\[\s*\^?\?|\^?\?|\[\s*==)(.*?)\]?$/);if(d){var e="";a.match(/^\./)&&(call("expand"),e=",true)"),call(d[1].match(/\=/)?"map":d[1].match(/\^/)?"distinctFilter":"filter");return e+",function($obj){return "+d[2]+"})"}d=a.match(/^\[\s*([\/\\].*)\]/);if(d)return".concat().sort(function(a,b){"+d[1].replace(/\s*,?\s*([\/\\])\s*([^,\\\/]+)/g,function(a,b,c){return"var av= "+c.replace(/\$obj/,"a")+",bv= "+c.replace(/\$obj/,"b")+";if(av>bv||bv==null){return "+(b=="/"?1:-1)+";}\nif(bv>av||av==null){return "+(b=="/"?-1:1)+";}\n"})+"})";d=a.match(/^\[(-?[0-9]*):(-?[0-9]*):?(-?[0-9]*)\]/);if(d){call("slice");return","+(d[1]||0)+","+(d[2]||0)+","+(d[3]||1)+")"}if(a.match(/^\.\.|\.\*|\[\s*\*\s*\]|,/)){call("expand");return(a.charAt(1)=="."?",'"+c+"'":a.match(/,/)?","+a:"")+")"}return a}).replace(/(\$obj\s*(\.\s*[\w_$]+\s*)*)(==|~)\s*`([0-9]+)/g,makeRegex).replace(/`([0-9]+)\s*(==|~)\s*(\$obj(\s*\.\s*[\w_$]+)*)/g,function(a,b,c,d,e){return makeRegex(a,d,e,c,b)}),query=prefix+(query.charAt(0)=="$"?"":"$")+query.replace(/`([0-9]+|\])/g,function(a,b){return b=="]"?"]":str[b]});var executor=eval("1&&function($,$1,$2,$3,$4,$5,$6,$7,$8,$9){var $obj=$;return "+query+"}");for(var i=0;i0&&(this.currSearch=this.createSearchObject(a));return!1},evalJsonQuery:function(a,b){if(b!=13)return!0;var c=Lib.getElementsByClass(this._body,"domBox");for(var d=0;d