title: Can Codeigniter write_file write a UTF-8 file?
body: <p>In CodeIgniter, I'm writing an XML file using write_file function.</p>
  
  <pre><code>write_file('data.xml', $str_xml);
  </code></pre>
  
  <p>But the encoding of the file is always ANSI. How can I have this 
  file be encoded to UTF-8 automatically?</p>