This PR changes (delete as applicable)
Describe the changes below:
Added accept headers to xhrLoad.
Added file type mappings to accept headers.
Yeah ok, let's add this in. In future please adhere to the coding style set out in the rest of the library though (you'll see what I mean when I edit your code, and re-push it, in a moment)
Tidy up formatting for #2585