zazi1991i / harviewer

Automatically exported from code.google.com/p/harviewer
0 stars 0 forks source link

Can use the web based preview to view this file, but not the embed #65

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
If you paste the code in the web based application everything works well, but 
not if I use the embed method

here is an example of my embed code:

<body class="harBody">
  <script>
  (function() {
      var har = document.createElement("script");
      har.src = "/test/har.js";
      har.setAttribute("id", "har");
      har.setAttribute("async", "true");
      document.documentElement.firstChild.appendChild(har);
  })();
  if(typeof(harInitialize)!="undefined"){harInitialize()}
  </script>
    <div class="har" data-har="http://localhost:8080/test/A.har"></div>
</body>

Original issue reported on code.google.com by ren...@gmail.com on 14 Sep 2011 at 6:34

Attachments:

GoogleCodeExporter commented 8 years ago
The attached har file is not valid.

I am seeing following error (when loading it into the HAR Viewer):

log.entries[47].timings     is missing and it is not optional

Honza

Original comment by odva...@gmail.com on 18 Sep 2011 at 10:52

GoogleCodeExporter commented 8 years ago
Is there a way to display the data anyway ??

seem like the behavior is not the same when you embed vs past the code in the 
sample application 

Original comment by ren...@gmail.com on 18 Sep 2011 at 6:01

GoogleCodeExporter commented 8 years ago
Patch committed at R396

- The validation for embedded HAR files can be switched off (use 'validate' 
attribute).
<div class="har" data-har="A.har" validate="false"></div>

Note: if the HAR file URL starts with http, the HAR file is supposed to be in 
HARP format (JSONP). Use "/" to specify absolute path to load HAR files (must 
be from the same domain).

See also: 
http://code.google.com/p/harviewer/source/browse/trunk/webapp/har.js#14

Will be in HAR Viewer 2.0.14

Honza

Original comment by odva...@gmail.com on 28 Sep 2011 at 2:33

GoogleCodeExporter commented 8 years ago
Thanks, you rock 

Original comment by ren...@gmail.com on 28 Sep 2011 at 2:56

GoogleCodeExporter commented 8 years ago
Selenium test at R397

Honza

Original comment by odva...@gmail.com on 28 Sep 2011 at 3:10

GoogleCodeExporter commented 8 years ago
This issue is fixed in HAR Viewer 2.0.15
http://www.softwareishard.com/har/viewer/

Please let me know if it works for you.

Thanks!
Honza

Original comment by odva...@gmail.com on 13 Nov 2011 at 2:34