Edit report at https://bugs.php.net/bug.php?id=64028&edit=1
ID: 64028 Updated by: ahar...@php.net Reported by: mike at kristopeit dot com Summary: include_path starting with "." doesn't actually start the search in current dir -Status: Open +Status: Feedback Type: Bug -Package: Dynamic loading +Package: Scripting Engine problem Operating System: CentOS PHP Version: 5.3.21 Block user comment: N Private report: N New Comment: I can't reproduce this, but bear in mind that . doesn't mean "the directory of the file PHP is currently executing", but rather "the current working directory of the process". Which directory are you invoking PHP in, and what does echo getcwd(); indicate your current working directory is before your include? Is it /some/dir or the directory file.php is in? If that all seems right, I suspect we'll need a self contained reproduce script from you. Previous Comments: ------------------------------------------------------------------------ [2013-01-18 22:10:54] mike at kristopeit dot com Description: ------------ i have code that runs via the command line... the php include path is set to ".:/some/dir" that code does an include("file.php"); for a file that is in the same directory. that file is included correctly. then in "file.php" i have include("another_file.php"); for another file in the same directory... but there is also a file at /some/dir/another_file.php... using a backtrace log i see that the /some/dir/another_file.php is being included instead of the file in the current directory. i changed the include("another_file.php"); to be include("./another_file.php");, and now everything works. this is a pretty obvious bug. ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=64028&edit=1