In MySQL I have set my data field type to utf8_bin and i am storing data in Unicode. Texts are being properly displayed in web pages.
I want to generate ex
I have a variant to Sajal response and found it on php.net at : http://www.php.net/manual/en/function.iconv.php#104287
Echo this at the begining of the content of the csv :
chr(255).chr(254).iconv("UTF-8", "UTF-16LE//IGNORE", $data)
I prefer with iconv() but it seems it do the same as mb_convert_encoding().
Don't forget to replace ; by tabs (\t) and it worked fine for me like this !