I am generating a csv file with php.
It works fine in windows, linux. But in mac (excel) it comes in a messed way.
All data comes in one column and does not get seperated by commas.
I was wondering if there is any way to pass headers for mac excel so it identifies the seperator (comma) by default.
Here are the header that I been using.
header("Content-type: application/vnd.ms-excel");
//header('Content-type: application/ms-excel');
//header("Content-Type: text/x-csv");
header("Content-disposition: csv" . date("Y-m-d") . ".xls");
header("Content-disposition: filename=".$filename.".xls");
header("Content-Type: application/force-download");
header("Content-Transfer-Encoding: binary");
header("Content-Length: ".strlen($csv_output));
header("Pragma: no-cache");
header("Expires: 0");
Thanks Abhi