Edit report at http://bugs.php.net/bug.php?id=53849&edit=1
ID: 53849 Updated by: paj...@php.net Reported by: nevermind at phpsimplicity dot com Summary: Nested includes not resolved -Status: Open +Status: Bogus Type: Bug Package: *Directory/Filesystem functions Operating System: Windows XP SP3 PHP Version: 5.3.5 Block user comment: N Private report: N New Comment: Sorry, but your problem does not imply a bug in PHP itself. For a list of more appropriate places to ask for help using PHP, please visit http://www.php.net/support.php as this bug system is not the appropriate forum for asking support questions. Due to the volume of reports we can not explain in detail here why your report is not a bug. The support channels will be able to provide an explanation for you. Thank you for your interest in PHP. Previous Comments: ------------------------------------------------------------------------ [2011-01-26 17:52:02] nevermind at phpsimplicity dot com Description: ------------ I have the following structure: common/a.php parent/b.php parent/child/c.php Now, in c.php, I included the file b.php from the "parent" folder using relative path. b.php includes a.php from "common" folder using also relative path. When I call c.php, it fails to include common/a.php within parent/b.php However, when I call b.php it includes common/a.php with no problem. And just to be clear, I have code in b.php (the actual one) that I need to keep separate from both a.php and c.php.. I have two physically different servers: Development: - Windows XP SP3 - Zend Server Community Edition 5.0.2 (Running PHP 5.3.2) Production: - Windows 2000 Small Business Server - Apache 2.2 - PHP 5.3.5 (As Apache module) Test script: --------------- [a.php] <?php echo 'I am in!'; [b.php] <?php require_once '../common/a.php'; [c.php] <?php require_once '../b.php'; Expected result: ---------------- When c.php is executed, the inclusion of common/a.php and the output of: "I am in!" Actual result: -------------- Production Server: Warning: require_once(../common/a.php): failed to open stream: No such file or directory in D:\Program Files\Apache Software Foundation\Apache2.2\htdocs\test\parent\b.php on line 3 Fatal error: require_once(): Failed opening required '../common/a.php' (include_path='.;C:\php\pear') in D:\Program Files\Apache Software Foundation\Apache2.2\htdocs\test\parent\b.php on line 3 Development Server: Warning: require_once(../common/a.php) [function.require-once]: failed to open stream: No such file or directory in C:\Program Files\Zend\Apache2\htdocs\test\parent\b.php on line 2 Fatal error: require_once() [function.require]: Failed opening required '../common/a.php' (include_path='.;C:\Program Files\Zend\ZendServer\share\ZendFramework\library') in C:\Program Files\Zend\Apache2\htdocs\test\parent\b.php on line 2 ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/bug.php?id=53849&edit=1