Hi Chris,
    The mode rw is contradictory. You say open the file in the read-only and
write-only modes. I think you the append mode(a) is the candidate to solve
your problem.

    Ferhat Can

----- Original Message -----
From: "Chris Blake" <[EMAIL PROTECTED]>
To: "PHP General" <[EMAIL PROTECTED]>
Sent: Monday, February 24, 2003 10:55
Subject: [PHP] fopen woes....


> Greetings,
>
> According to PHP manual example this is supposed to open a file and
> write a line of text to it....but it doesn`t.
> ===================================================================
> <html>
> <head>
> <title>File Open</title>
> </head>
>
> <body>
> <?php
>
> $handle = fopen ("/home/data/ClientWebs/chrisplay/Things/fopen.txt",
> "rw");
> fwrite($handle, "Hello there!");
> fclose($handle);
>
>
> ?>
>
> </body>
> </html>
> ====================================================================
>
> But my text file is blank......some of the other code samples I looked
> at on www.php.net/fopen don`t provide specific help..
>
>
> --
> Chris Blake
> Office : (011) 782-0840
> Cell : 083 985 0379
> It is reported that somewhere in the world, every 15 seconds, a woman
> gives birth to a child. She must be found and stopped.
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to