note 23734 added to function.dirname
| From: | oliver at hankeln-online dot de | Date: | Fri, 26 Jul 2002 09:14:55 +0000 |
| Subject: | note 23734 added to function.dirname | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-33577@lists.php.net to get a copy of this message | ||
As mentioned in the first posting, dirname() does not recognize /foo/ as a dir.
While in some cases this may be quite annoying, it can also be considered a feature:
You can easily go up the path with
dirname(dirname("/foo/bar/test.php"));
This will return "/foo".
--
http://www.php.net/manual/en/function.dirname.php
http://master.php.net/manage/user-notes.php?action=edit+23734
http://master.php.net/manage/user-notes.php?action=delete+23734
http://master.php.net/manage/user-notes.php?action=reject+23734