title: Create a temp file with a specific extension using php
body: <p>How do I create a temporary file with a specified extension in php.
  I came across <a href="http://php.net/manual/en/function.tempnam.php"><code>tempnam()</code></a> but using it the extension can't be specified.</p>