I created and saved a text file(containing simple text) in windows then uploaded it to the unix server, apache/mysql/php and then created a download page with the following code
$path = 'myfile.txt';
header ( "Content-Type: application/octet-stream");
header ( "Content-Length: " . filesize ( $path ) );
header ( 'Content-Disposition: attachment; filename=' . $path );
readfile($path);
But when I download it by visiting the download page and open the text file in notepad it shows with out the line breaks.
What can I do to solve it ?