PHP 4.0 Bug #5707: dirname does not handle paths not starting with "/" properly

From: Date: Thu, 20 Jul 2000 17:29:56 +0000
Subject: PHP 4.0 Bug #5707: dirname does not handle paths not starting with "/" properly
Groups: php.dev 
Request: Send a blank email to php-dev+get-25253@lists.php.net to get a copy of this message
From: ccurtis@aet-usa.com Operating system: Linux (debian/unstable) PHP version: 4.0.0 PHP Bug Type: Misbehaving function Bug description: dirname does not handle paths not starting with "/" properly echo dirname( "/1/2/3" ) . " --" . dirname( "/1/2" ) . " --" . dirname( "/1" ) . "<br>" . dirname( "1/2/3" ) . " --" . dirname( "1/2" ) . " --" . dirname( "1" ) . "<p>"; These should produce the same output in the final condition: a null/empty string, but this is the output: /1/2 --/1 -- 1/2 --1 --1

« previous php.dev (#25253) next »