php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #12896 is_directory should point to is_dir
Submitted: 2001-08-22 09:50 UTC Modified: 2002-06-17 17:50 UTC
From: mikep at oeone dot com Assigned:
Status: Not a bug Package: Feature/Change Request
PHP Version: 4.0.6 OS:
Private report: No CVE-ID: None
 [2001-08-22 09:50 UTC] mikep at oeone dot com
For the sake of consistency, the function is_directory should be made and should be the same as is_dir(). All the other is_* functions contain full word names.

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2001-08-22 10:44 UTC] sniper@php.net
reclassified.

 [2002-06-17 16:12 UTC] sniper@php.net
No, we don't really need more names for same functions.
is_dir() is short and nice.


 [2002-06-17 17:50 UTC] mikep at oeone dot com
You don't need more names for functions, but having consistently named functions was basically the point of this bug.
The is_dir function is different from all the other is_ file functions in that it doesn't contain the complete word. At least in the future it should be noted that its easier for programmers if all the functions are named in a consistent manner.
By the way, I would also like to point out that is_executable contains more letters than is_directory, yet is_dir is shortened and is_executable is not.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Tue Jul 16 20:01:29 2024 UTC