Re: Problem: mysqli class not found

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



David,


> I have an install of PHP 5 on Windows 2003 Server with Apache 2 and when I
> reference mysqli in my php code, I get an error that the mysqli class is not
> found.

I've wrestled with Windows 2000 Server with Apache 2 configuration,
and hopefully this will apply for 2003 as well.


> I looked at the php.ini file and I added a line for php_mysqli in the
> extensions section and I edited the extension_dir directive to point to
> c:\php\ext folder (I used "/php/ext" as the value assigned to the directive.
> 
> I made sure that the c:\php\ext folder actually had a file called
> php_mysqli.dll, which it did.

Somehow PHP ISAPI can't seem to find your extensions folder.  In my
setup, I also have PHP installed into c:\php\ext, and in effect, in my
PHP.INI I set

extension_dir = C:\php\ext

...which works just fine.  I don't think you need to use the UNIX path
structure, and that may be the root of your problem.

Another thing to check would be NTFS permissions on the PHP.INI file. 
If the user that Apache2 is running under cannot read the PHP.INI
file, then none of your extra configuration directives would appy.

Also, I think there is a bulletproof way to ensure everything works,
just in case you installed some additional extension that requires
some extra DLLs you don't want to drop into your SYSTEM32 directory. 
You can add "c:\php\ext" into your global windows environment
variable.  I've found that to work out well in the long run if you
have additional extensions and dependencies.


> No I can't start my Apache server.
> 
> I had done a default install of both Apache 2 and PHP 5.
> 
> Any ideas as to how I can get the mysqli class identified and allow my
> Apache server to start.

Apache can't start properly when the extension can't be found.  But,
if the above works and you're able to start up Apache, write a small
script and put in

<? phpinfo(); ?>

and run through the wealth of information that is displayed to make
sure "mysqli" is installed as an extension.


/sylikc

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux