title: How to use dompdf within Zend-Framework?
body: <p>I have the following code inside my controller but I can't open the pdf it produces.</p>
  
  <pre><code>    $html = "&lt;html&gt;&lt;head&gt;&lt;meta http-equiv='Content-Type' content='text/html; charset=utf-8'&gt;&lt;/head&gt;&lt;body&gt;trial&lt;/body&gt;&lt;/html&gt;";
  
      $dompdf = new DOMPDF();
      $dompdf-&gt;load_html($html);
      $dompdf-&gt;render();
      $dompdf-&gt;stream("sample.pdf");  
  </code></pre>
  
  <p>It works when used outside the framework but I don't know how to check how the pdf is mangled in any way. Any help will be appreciated!</p>
  
  <p>EDIT:</p>
  
  <p>I'm using Zend Framework 1.10 and followed this tutorial</p>
  
  <pre><code>http://www.encapsulated.org/blog/2009/08/27/how-to-let-dompdf-and-zend-framework-play-along/
  </code></pre>