Is it possible to use multiple header types in one document? For example:
header("Content-type: image/jpeg");
header('Content-Type: text/html; charset=utf-8');
returns the whole page as text/html… while
header('Content-Type: text/html; charset=utf-8');
header("Content-type: image/jpeg");
Returns the whole page as an image…. How can I use both types of content on the same page? I’m using ob_start() at the top and ob_end_flush() at the beginning.
You can’t. But what you can do is something like this in your HTML:
Of course
my_img.phpwould be a PHP file that has aheader("Content-type: image/jpeg");
line, and outputs your image.