ID: 25381 User updated by: ulysses at mail dot fitan dot com dot tw Reported By: ulysses at mail dot fitan dot com dot tw Status: Bogus Bug Type: Scripting Engine problem Operating System: Windows 2K, IIS5 PHP Version: 4.3.3 New Comment:
> RTFM: http://www.php.net/include_once Do you mean this ? > Note: Be aware, that the behaviour of include_once() > and require_once() may not be what you expect on a > non case sensitive operating system (such as Windows). How convenient! Then please tell me, WHAT CAN I EXPECT ? My code runs well on 4.30, and crashed when my client upgrade their system to 4.33, can I tell me client to RTFM ? I just demand for a notice message, or do you want Windows developers to build a included_file_array by their self in all code ? No wonder why there are so few enterprises who would adopt PHP for critical task. Cause it can not be EXPECTED! Previous Comments: ------------------------------------------------------------------------ [2003-09-03 10:48:11] [EMAIL PROTECTED] RTFM: http://www.php.net/include_once ------------------------------------------------------------------------ [2003-09-03 10:00:15] ulysses at mail dot fitan dot com dot tw Description: ------------ In PHP 4.3.3 include_once() is case-sensitive. This will cause some problem on case-insensitive filesystems, such as Windows. Please see the reproduce code. Of course I will never use this teenager-hacker-style strings for actual coding, but it means trouble when mixed using relative and absolute path within codes. I spent hours debugging, only to found it's the "I"netpub directory (IIS default setting) name problem. Yes, this problem can be work-around. But if include_once() feels that 'C:/Inetpub/wwwroot/b.php' and 'c:/inetpub/ wwwroot/b.php' are different, please do not let me include it, or please give me some warning. This had never happened in PHP 4.3.2 or previous version. Reproduce code: --------------- I've got two files: a.php & b.php, which are put in the same directory. The actual absolute to b.php is 'C:/Inetpub/wwwroot/b.php'; a.php: <? $mydir = 'c:/inEtpUB/wwwRoOT'; echo "<P>THIS IS A.PHP"; include_once("b.php"); include_once("$mydir/b.php"); ?> b.php <? echo "<P>THIS IS B.PHP"; ?> Expected result: ---------------- THIS IS A.PHP THIS IS B.PHP Actual result: -------------- THIS IS A.PHP THIS IS B.PHP THIS IS B.PHP ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=25381&edit=1