RE: [PHP] re: Overwriting specific lines in text files without re writingthe whole thing.

From: Date: Tue, 27 Jun 2000 15:55:04 +0000
Subject: RE: [PHP] re: Overwriting specific lines in text files without re writingthe whole thing.
Groups: php.general 
Request: Send a blank email to php-general+get-3360@lists.php.net to get a copy of this message
There is an fflush() function in PHP but it´s not documented yet. http://www.zugeschaut-und-mitgebaut.de/php/function.fflush.html Since I´m not at all into C, could someone describe what fflush() does and why it´s important to use it "appropriately when doing random access in the file"? regards --marten > -----Original Message----- > From: Bill Rausch [mailto:bill@numerical.com] > Sent: Tuesday, June 27, 2000 5:30 PM > To: Carroll Barrett > Cc: php-general@lists.php.net > Subject: Re: [PHP] re: Overwriting specific lines in text > files without > rewritingthe whole thing. > > > Well I'll be a ... :-) > > I've only been using PHP for two weeks. I didn't realize > those functions > existed. It appears that they would work, since there is > also an fseek() > and ftell() available. If he's just got a few entries, > consecutive freads > would work till you found the entry of interest. If he's got > a lot, then > some random access would be useful. > > If these functions work like the ANSI C functions, then you > have to be very > careful to use fflush() appropriately when doing random > access in the file. > I don't see an fflush() in PHP. Does that mean it's not necessary? > > Bill

« previous php.general (#3360) next »