Doc #67048 [Ver->Csd]: pathinfo() doesn't document parsing of dot-files

From: Date: Wed, 22 Jun 2016 14:18:17 +0000
Subject: Doc #67048 [Ver->Csd]: pathinfo() doesn't document parsing of dot-files
References: 1  Groups: php.doc.bugs 
Request: Send a blank email to doc-bugs+get-13586@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=67048&edit=1 ID: 67048 Updated by: cmb@php.net Reported by: russellbarnhart at gmail dot com Summary: pathinfo() doesn't document parsing of dot-files -Status: Verified +Status: Closed Type: Documentation Problem Package: Filesystem function related Operating System: *nix PHP Version: Irrelevant Assigned To: cmb Block user comment: N Private report: N New Comment: This bug has been fixed in the documentation's XML sources. Since the online and downloadable versions of the documentation need some time to get updated, we would like to ask you to be a bit patient. Thank you for the report, and for helping us make our documentation better. Previous Comments: ------------------------------------------------------------------------ [2016-06-22 14:17:25] cmb@php.net Automatic comment from SVN on behalf of cmb Revision: http://svn.php.net/viewvc/?view=revision&amp;revision=339450 Log: Fix #67048: pathinfo() doesn't document parsing of dot-files ------------------------------------------------------------------------ [2015-02-15 21:20:37] cmbecker69 at gmx dot de pathinfo's behavior wrt. "hidden" files might be debatable (under the assumption that extension is defined as everything after the rightmost dot in the basename, it is not a bug). However, the behavior is the same since PHP 4.3 at least[1], so changing it would be a massive BC break. I suggest to improve the documentation, and to change the issue to "Documentation problem" respectively. [1] <http://3v4l.org/hsDPm> ------------------------------------------------------------------------ [2014-04-09 12:51:22] russellbarnhart at gmail dot com Description: ------------ The function pathinfo() assumes all files that have a basename starting with a period only have an extension. This bug is present in at least 5.3.x to 5.5.x. Test script: --------------- # copy & paste into a shell php -r "print_r(pathinfo('/some/path/.test'));" Expected result: ---------------- Array ( [dirname] => /some/path [basename] => .test [extension] => [filename] => .test ) Actual result: -------------- Array ( [dirname] => /some/path [basename] => .test [extension] => test [filename] => ) ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=67048&edit=1

« previous php.doc.bugs (#13586) next »