I dont know any function doing this in fast way. But If you want something
simple, check how I do it :
$file = file("file.txt");
$numLine = count($file);
"W. Paulisse" <ihatespam.nl> wrote in message
> Currently i have a logfile which tracks a certain feature on my server.
> Every time the feature accurs my script appends a line in the file.
> Can i find out how many lines the log file currently contains without
> opening the complete file en count every line in a loop?
> I want to do this because reading the file every time can take a long> the log file is emptied every week but on the end of the week the file
> contains more than 20.000 lines.
> Thanks in Afvance
> W. Paulisse