Hello,
I am trying to download the excel file and upon downloading the file, the time in file name is changed. Here is the code snippet:
fileName = "XYZ_10-Apr-2015_13:14:52.csv";
header("Content-type: application/x-msexcel");
header("Content-disposition: attachment; filename=\"$fileName\"");
header("Pragma: no-cache");
header("Expires: 0");
However, in the downloads folder, the name of the file is "XYZ_10-Apr-2015_13_14_52.csv". I am trying to figure out the reason why my file name is changed upon download i.e. ":" is changed to "_" in time portion.
Can someone please help with this issue.
Thanks,
SK
Problem with time format in filename using content dispositi
Moderator: General Moderators
Re: Problem with time format in filename using content dispo
You can't use : in a file name