My code is simple:
<?php var_dump(headers_sent()); ?>
It depends if your
output_buffering directive in
php.ini file. If it is
output_buffering = Off
echo headers_sent() should output
In other cases,
headers_sent() won't output any results because it will be FALSE. The headers won't be sent because the output is buffered.
If you want to get around this and force-send headers, you can use
Hope this helps!