note 49939 added to function.count
| From: | david_at_webgroup_dot_org at osu1 dot php dot net | Date: | Sun, 13 Feb 2005 00:30:39 +0000 |
| Subject: | note 49939 added to function.count | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-84908@lists.php.net to get a copy of this message | ||
While michael at htmlland dot net's code works, I believe it is better to use:
$extension=substr($file,strrpos($file,".")+1);
This doesn't incur the overhead of array handling. I haven't tested it for time
functions, but it should work just as well and SHOULD be faster.
----
Manual Page -- http://www.php.net/manual/en/function.count.php
Edit -- http://master.php.net/manage/user-notes.php?action=edit+49939
Delete: added to the manual -- http://master.php.net/manage/user-notes.php?action=delete+49939&report=yes&reason=added+to+the+manual
Delete: bad code -- http://master.php.net/manage/user-notes.php?action=delete+49939&report=yes&reason=bad+code
Delete: spam -- http://master.php.net/manage/user-notes.php?action=delete+49939&report=yes&reason=spam
Delete: useless -- http://master.php.net/manage/user-notes.php?action=delete+49939&report=yes&reason=useless
Delete: other reasons -- http://master.php.net/manage/user-notes.php?action=delete+49939&report=yes
Reject -- http://master.php.net/manage/user-notes.php?action=reject+49939&report=yes
Search -- http://master.php.net/manage/user-notes.php