We have to set the right mime type to the content, otherwise it would be replaced with text/html one later.