image.php: Remove leading line from images; Set correct Content-type header.

image.php always gives a leading empty line on images and always gives an image/png Content-type header.
This patch removes the leading line and gets the correct MIME type from the cached image.