extension_dir is meaningless with PHP and Windows

UPDATE (11-8-06): It’s a documentation bug. The Windows installation document says to use the PATH environment variable to tell PHP where to find php.ini. In fact, PHP does not check the PATH for php.ini per badly buried configuration file documentation. Once I got that fixed, that fixed the extension_dir problem.

UPDATE (11-8-06): Predictably, this bug got classified as “bogus.” I’ve gotten it reclassified as “open.”

I despise PHP because it is a low tech, rudimentary, Perl-based script kiddie language. There is no reason for any serious programmer to use PHP for new products. Despite this, I’m having to use it for another web product I am checking out.

Yet again, I ran into another idiotic PHP bug. Unlike last time, the php folks seem to be taking me seriously instead of reflexively dismissing complaints from non-UNIX users.

PHP comes with a bunch of extensions. Any connection to a database uses an extension.

The php.ini file allows you to specify the location of your extensions directory. This declaration in Windows systems would typically be:

; Directory in which the loadable extensions (modules) reside.
extension_dir = c:\PHP\ext

Unfortunately, the extension_dir directive is totally meaningless. I verified that through Sysinternal’s Filemon utility. PHP never checks the extension_dir! Your extensions have to be in a location specified in the system path. I’ll let you check the bug report for more details.

Leave a Reply

Your email address will not be published. Required fields are marked *