[eluser]Joe_Archer[/eluser]
Hi, I'm fairly well versed with CI and have been using it for around a year, successfully, both inside and outside of work.
As a little side project I'd like to produce a random image script which when called, selects an image from a folder at random and returns it to the browser.
I don't have a problem writing the code to do this, it's very straight forward, what I'm not sure about though, is how to return "just an image" to the browser. I don't want to output any HTML, I just want to return an image file as though the file had been browsed to directly on the server. I assume I'll need to set a mime type/header to do this, but I'm not sure how I'd go about doing so.
Any help greatly appreciated.