@amras1 - I haven't reviewed this in detail, but is there a way to make the HTML output more tidy? i.e.

```
<tr>
  <th>title1</th>
  <th>title2</th>
...
```