ID: 21565 Updated by: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] -Status: Open +Status: Feedback Bug Type: Scripting Engine problem Operating System: Tru64Unix 5.1A PHP Version: 4.3.0 New Comment:
It is likely that your error reporting level is such that warning messages do not get shown. Unlike require which fails with an error include will only output a warning on failure. Beyond that there is very little difference between the require/include code none of which is the code reponsible for actually openning files. Previous Comments: ------------------------------------------------------------------------ [2003-01-10 03:35:37] [EMAIL PROTECTED] After upgrade from PHP 4.2.2 to 4.3.0 I encountered the problem with safe_mode in conjunction with require(). Example: [php.ini] safe_mode = On; include_path = ".:./:/path/to/my/app/dir"; safe_mode_include_dir = ".:./:/path/to/my/app/dir"; [/path/to/my/app/dir/index_working.php] - works fine for me <?php include "header.php"; ?> [/path/to/my/app/dir/index_buggy.php] - throws error <?php require "header.php"; ?> The error: [error] PHP Fatal error: main() [<a href='http://www.php.net/function.main'>function.main</a>]: Failed opening required 'header.php' (include_path='.:./:/path/to/my/app/dir') in /path/to/my/app/dir/index_buggy.php on line 2 Operating system: Tru64Unix 5.1a Webserver: Apache 1.3.26 ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=21565&edit=1