PHP 4.0 Bug #9592: print __FILE__ doesn't return full path when using include_once

From: Date: Wed, 07 Mar 2001 01:27:33 +0000
Subject: PHP 4.0 Bug #9592: print __FILE__ doesn't return full path when using include_once
Groups: php.dev 
Request: Send a blank email to php-dev+get-48119@lists.php.net to get a copy of this message
From: vince@mha.ca Operating system: Linux 2.4.2 (RedHat 6.x) PHP version: 4.0.4pl1 PHP Bug Type: Unknown/Other Function Bug description: print __FILE__ doesn't return full path when using include_once When doing "print(__FILE__);" it only echo's the file name not the full path when the file is included with include_once or require_once. I don't know if this is a bug or not, but my programming staff seems to think its a bug. Example: # php -v 4.0.4pl1 # grep -C php test.* test.inc:<?php print (__FILE__."\n"); ?> -- test.php:<?php include_once("test.inc"); ?> # php -q test.php /root/test.inc # grep -C php test.* test.inc:<?php print (__FILE__."\n"); ?> -- test.php:<?php include_once("test.inc"); ?> # php -q test.php test.inc # -- Edit Bug report at: http://bugs.php.net/?id=9592&edit=1

« previous php.dev (#48119) next »