I\'ve got this very simple thing that just outputs some stuff in CSV format, but it\'s got to be UTF-8. I open this file in TextEdit or TextMate or Dreamweaver and it displa
In my case following works very nice to make CSV file with UTF-8 chars displayed correctly in Excel.
$out = fopen('php://output', 'w'); fprintf($out, chr(0xEF).chr(0xBB).chr(0xBF)); fputcsv($out, $some_csv_strings);
The 0xEF 0xBB 0xBF BOM header will let Excel know the correct encoding.
0xEF 0xBB 0xBF