When i try to insert polish character in Csv file .The polish character automatically turned to their respective htmlentities
<?php
header('Content-Type: text/csv; charset=UTF-8');
header( 'Content-Disposition: attachment;filename=reports.csv');
echo ('åĄĆĘŁŃÓŚŹŻąćęłńóśźż');
?>
Output: åĄĆĘŁŃÓŚŹŻąćęłńóśźż
I need polish character to be displayed there.
Can anyone help me in order to solve this?
Thank you
Try this:
Also do not forget to save your php file as UTF-8 without BOM …
chr(9)seprates fields andchr(13)separates rows …