Well, fopen() use to be a common choice here.
On Mon, 2003-10-13 at 19:58, Harpreet wrote:
> I am parsing an xml file and show the data in text boxes in a form .
> I want to edit the data and then update the file.
>
> How can i go about editing a file using php
>
> Help is appreciated
>
> Regar
I am parsing an xml file and show the data in text boxes in a form . I want
to edit the data and then update the file.
How can i go about editing a file using php
Help is appreciated
Regards,
Harpreet
--
PHP Windows Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/u
>this doesn't work. It will still write the new line after the line (I matched).
>Everytime I read a line from a file, the $fd gets incremented, so when I say fwrite,
>$fd is already pointing to the next line in the file? Any suggestions as to working
>around this? I can't rewrite the entir
jas
Subject: RE: [PHP-WIN] Writing to a file
You should use regex (regular expressions) to do this, because is simpler.
You can get the contents of the files into a variable:
Hope it helps!
Byes!
MG29
-Mensaje original-
De: Gerardo Rojas [mailto:[EMAIL PROTECTED]
Enviado el: Jueves, 25 d
Val[0] );
break;
}
--
-Original Message-
From: Mike Brum [mailto:[EMAIL PROTECTED]
Sent: Thursday, September 25, 2003 3:11 PM
To: Gerardo Rojas; [EMAIL PROTECTED]
Subject: RE: [PHP-WIN] Writing to a file
I guess this all depends on how you're writing to the file. Without
the former data no longer exists.
-M
-Original Message-
From: Gerardo Rojas [mailto:[EMAIL PROTECTED]
Sent: Thursday, September 25, 2003 2:09 PM
To: [EMAIL PROTECTED]
Subject: [PHP-WIN] Writing to a file
I'm am able to open the file read and write to it. The problem is that I
wa
I'm am able to open the file read and write to it. The problem is that I want to
replace a line of text with another line. My function is actually writing my new line
after the line I wanted to change. Can we do arithmetic on the $fd (file handle or
file descriptor)? To tell PHP to write whe