title: Content-type ignored
body: <p>this is my first question to the community, although I usually find all the answers I need on the forum, I had no luck on this one.</p>
  
  <p>The problem is I have a php script witch outputs an inline pdf like so:</p>
  
  <pre><code>$doc = base64_decode( $rapport );
  
  header('Content-type: application/pdf');
  
  header("Content-Disposition: inline; filename='rapport.pdf'");
  
  echo $doc;
  </code></pre>
  
  <p>But it only works when i open the page as an admin on my wordpress site.</p>
  
  <p>If another user opens it, the Content-type header just get ignored ... but i can see the bytes of the doc.</p>
  
  <p>I tested myself by opening the same page in the same browser logged in as another user and the header I see in chrome dev-tool is Text while it is application/pdf normally.</p>
  
  <p>Any help would be appreciated.</p>
  
  <p>Thx!</p>
  
  <p><strong>Edit</strong>: Problem half solved, the wp super cache plugin was compressing the output so everything works fine again without the cache... Any suggestions as how I should set the cache plugin to avoid breaking the dynamic content?</p>