Specify .doc file encoding when creating with php?
<p>Currently i try to create some of my database export work more automated and i decided to go with exporting data from MySql database to .doc file in php.</p>

<p>So im doing some database work and store complete html  to a $str variable and then write/make new file:</p>

<blockquote>
  <p>$fp = fopen($file, 'w+'); 
  fwrite($fp,$str);
  fclose($fp);</p>
</blockquote>

<p>The problem here is not creating .doc file, but when i download and view that .doc file it's not in UTF-8 it's in unicode.</p>
