note 20272 deleted from function.sizeof by jimw
| From: | jimw@php.net | Date: | Wed, 03 Apr 2002 18:57:23 +0000 |
| Subject: | note 20272 deleted from function.sizeof by jimw | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-28558@lists.php.net to get a copy of this message | ||
Re: the hit count example
Sure that will work because file() returns an array with the entire file contents and sizeof returns
the number of items in any mixed type sent to it, in this case lines in the array. Each new log
entry adds a line to the file and an entry to the file() array. But that's an incredibly
inefficient way to do a hit counter.