Re: [PHP-WIN] Re: fwrite()

2005-11-09 Thread Rosty Kerei
Gosh! JC, I used $_POST['textbox'] as an example for you. If you wish to end your lines by "\r\n" instead of "\n" just do it, like here $file_data = "editdate#".date('l d_m_Y')."\r\n"; And if you have some textareas on your HTML form, you can change them like $_POST['textbox'] = str_replace("\n

RE: [PHP-WIN] Re: fwrite()

2005-11-08 Thread JC Botha
eplace("\n", "\r\n", $_POST['textbox']); if (fwrite($handle, $file_data) === FALSE) { echo "Cannot write to file ($file_location)"; exit; } fclose($handle); } else { echo "The file $file_location is not writable"; } } -

Re: [PHP-WIN] Re: fwrite()

2005-11-08 Thread Kevin Smith
rom: Rosty Kerei [mailto:[EMAIL PROTECTED]] Sent: 08 November 2005 01:32 PM To: php-windows@lists.php.net Subject: [PHP-WIN] Re: fwrite() Maybe you need to replace "\n" to "\r\n"? Like - $_POST['textbox'] = str_replace("\n", "\r\n", $_POST['t

RE: [PHP-WIN] Re: fwrite()

2005-11-08 Thread JC Botha
@lists.php.net Subject: [PHP-WIN] Re: fwrite() Maybe you need to replace "\n" to "\r\n"? Like - $_POST['textbox'] = str_replace("\n", "\r\n", $_POST['textbox']); Sincerely, Rosty Kerei [EMAIL PROTECTED] ""JC Botha"" <[EMAIL

[PHP-WIN] Re: fwrite()

2005-11-08 Thread Rosty Kerei
Maybe you need to replace "\n" to "\r\n"? Like - $_POST['textbox'] = str_replace("\n", "\r\n", $_POST['textbox']); Sincerely, Rosty Kerei [EMAIL PROTECTED] ""JC Botha"" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Dear Users, thanks for those that helped me last time! I got it

[PHP-WIN] Re: fwrite is adding blank lines

2002-10-15 Thread benjamin delman
I thought I would display this code in the body of the message, because I dont want people to worry about the attachment containing a virus. Can't seem to figure out why this is added blank lines when writing the file. The DEFAULT case opens the file and loads it into a Form Textarea. CASE 1 then