Add statuscode to ajax and history view

This one contains the original changes for [Glimpse pull request 609](https://github.com/Glimpse/Glimpse/pull/609)

The generated glimpse.js file has been copied to the pull request above