找不到“mysqli”类

under the Apache/2.0.65 (Win32) PHP/5.2.13 Server .. when i run CMD line and input :php -r "new mysqli();" CMD return :Fatal error: Class 'mysqli' not found in Command line code on line 1

then i configure the php.ini and remove the comment from the start of the line extension=php_mysqli.dll , and set extension_dir = "C:\PHP\ext" , even i copy the libmysql.dll and php_mysqli.dll to c:\windows\system32. but it's still can't work ..

and run it again and still failed.

i run in windows7 apache 2.0 and php 5.2

who can help me ,,thanks

You set extension_dir = "C:\PHP\ext" in your php.ini. However you put PHP extension in C:\windows\system32.

php_mysqli.dll must be in C:\PHP\ext.

I was having this same problem, and my problem was that I had the php.ini-production and php.ini-development files. I had to remove the '-production' from the end of my php.ini-production file to make it 'php.ini'. Then, I had to make sure I had uncommented the 'extension=mysqli' and change 'extension_dir="ext"' to 'extension_dir="c:/php/ext"'.

Also, I originally had my php base file named PHP7, and so I changed it to 'php'. Not sure if this was part of the solution, but it's a step I took to get my mysqli library working.