Re: delete file contents before writing?

From: Date: Mon, 03 Jun 2002 15:41:34 +0000
Subject: Re: delete file contents before writing?
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-100411@lists.php.net to get a copy of this message
On Monday 03 June 2002 23:37, Jas wrote: > Not sure how I could do this as I could not find a functions on php.net to > allow me to first delete the entire contents of a file "before" writting > the changes supplied by a textarea. Here is what I have thus far: [snip] > As of right now it opens the file and writes your changes, however it > simply goes to the end of the file then begins writting. I would like to > delete the contents of the file, then write the changes. > Any help or pointers are appreciated! Read the manual entry for fopen() and see what it says about the 'w' flag. -- Jason Wong -> Gremlins Associates -> www.gremlins.com.hk Open Source Software Systems Integrators * Web Design & Hosting * Internet & Intranet Applications Development * /* Money can't buy love, but it improves your bargaining position. -- Christopher Marlowe */

« previous php.general (#100411) next »