/usr/bin/env php shebang prints headers when called via sudo or cron
<p>I am using <code>#!/usr/bin/env php</code> to invoke a PHP script at the command line, which has been working great. PHP correctly detects the command line and suppresses HTTP headers.</p>

<p>But I started calling my script via <code>sudo</code> or via a cron job, it has started print HTTP headers.</p>

<pre class="lang-none prettyprint-override"><code>&gt;&gt; ./test 
Hello world!

&gt;&gt; sudo -u nathan ./test 
Content-type: text/html

Hello world!
</code></pre>

<p>./test just contains the following code:</p>

<pre class="lang-php prettyprint-override"><code>#!/usr/bin/env php
&lt;?php

echo 'Hello world!' , "\n";
</code></pre>

<p>I think this has something to do with whether the script is passed a tty, but I am unsure. Is there a way to prevent these headers from being printed? I can't use the "-q" argument, I don't think, since I am calling it via env.</p>
