title: Phar archive outputs jibberish
body: <p>I've created my first phar archive with the following code:  </p>
  
  <pre><code>$phar = new Phar('myphar.phar');
  $phar-&gt;addFile("index.php");
  $phar-&gt;setStub($phar-&gt;createDefaultStub('index.php', 'index.php'));
  </code></pre>
  
  <p>The mentioned index.php only does a single output:  </p>
  
  <pre><code>echo "I am in a PHP archive!";
  </code></pre>
  
  <p>When I run the above code, myphar.phar is created and when I run in at the cli, the output is "I am in a PHP archive!".
  However, when I call the myphar.phar from a webbrowser, it prints some weird characters, like <code>????�???�?</code>, instead of my index.php contents and no error.</p>
  
  <p>I added the following line to my apache httpd.conf to support phar archives:</p>
  
  <pre><code>AddType application/x-httpd-php .phar
  </code></pre>
  
  <p>Does anybody know why it works on the cli, but not in the browser?</p>