I'm trying to determine if I should just directly
1) have PHP fetch an image binary and output (with header as image-type) image, eg:
/* $image = ... insert curl function to fetch image */
header('Content-Type: image/png');
echo $image;
or if I should have
2) a header redirect to the URL path of the image
header('Location: http://domain.com/pathtoimage/image.png');
Some initial questions:
In the first, would that amount to any overhead with PHP having to have the image in memory in order to output it?
In the second, would this lead to any errors on clients that somehow cannot follow the PHP header redirect?