note 22937 rejected from function.include-once by sniper

From: Date: Wed, 29 Jan 2003 04:36:53 +0000
Subject: note 22937 rejected from function.include-once by sniper
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-43013@lists.php.net to get a copy of this message
It seems like the appropriate answer to the case sensitivity problem in the require/include functions in Win32 is to wrap the function as such: function win_require_once($whatfile) { return require_once(strtoupper($whatfile); } Not only does this guarantee that all file handles passed it will be tracked correctly despite case, but also, this sort of handling dodges the issue with old DOS programs which typically overwrite filenames in uppercase on saving (important if you're dealing with legacy systems)

« previous php.notes (#43013) next »