title: When to use imap_qprint?
body: <p>I'm using PHP's <a href="http://www.php.net/manual/en/ref.imap.php" rel="nofollow">IMAP Functions</a> extension to check e-mail from a POP3 account.</p>
  
  <p>When it comes to actually fetching the message, I have the following code:</p>
  
  <pre><code>// Make new raw email message
  // With PHP Imap, we need to fetch headers and body separately!
  $body = imap_fetchheader($mailbox, $msgno);
  $body .= imap_qprint(imap_body($mailbox, $msgno));
  </code></pre>
  
  <p>All the examples I am able to find mentions that one should use <a href="http://www.php.net/manual/en/function.imap-qprint.php" rel="nofollow">imap_qprint()</a> here, but I've noticed that when I do all the GET parameters of a URI get mangled. </p>
  
  <p>For example, </p>
  
  <p><code>http://localhost/pronk.php?id=6248&amp;amp;key=c7eb7c5173e1525a47c63abc39d938e1</code> </p>
  
  <p>becomes: </p>
  
  <p><code>http://localhost/pronk.php?idb48&amp;amp;keyÇeb7c5173e1525a47c63abc39d938e1</code></p>
  
  <p>If I <em>don't</em> use <code>imap_qprint()</code> everything seems to work just fine. (I'm using <code>imap_body</code> instead of <code>imap_fetch_body</code> because I want the entire e-mail - headers, parts, and everything) But since all examples I can find say to use qprint, I wanted to know why my code seems to need it omitted?</p>