12

I downloaded and installed php7 from: http://windows.php.net/qa/#php-7.0-ts-VC14-x64

The php codes are running fine. I am not able to connect database using 'mysqli' Class. It says

Class 'mysqli' not found

I've uncommented extension=php_mysqli.dll in php.ini file. Did I miss anything while installing php7.

Dharman
  • 30,962
  • 25
  • 85
  • 135
gskhanal
  • 591
  • 1
  • 3
  • 12
  • Did you install a MySQL Server as well as PHP? – RiggsFolly Dec 13 '15 at 15:01
  • @RiggsFolly : I solved the issue, it was a silly mistake. I did not set the `extension_dir`, now I set it to `extension_dir = "C:\php7\ext"` and its working fine. Thanks. – gskhanal Dec 13 '15 at 15:18
  • @gskhanal, can you please post this as an answer to your own question and mark it as accepted? This helps tidy up the unanswered questions list and will also give you awesome-stackoverflow-points ;) – Will Dec 28 '15 at 01:45
  • I am experiencing the same issue and I tried setting the extension_dir to the absolute path. I tried with backslashes and forward slashes. None works. Any ideas? – feedc0de Apr 10 '17 at 07:12

1 Answers1

12

I solved the issue, it was a silly mistake. The extension_dir was not set. I set it to extension_dir = "C:\php7\ext" and its working fine.

gskhanal
  • 591
  • 1
  • 3
  • 12