[web] Cannot load MySQL Extension in PHP

Started by
4 comments, last by hkBattousai 16 years, 10 months ago
I receive an error like below on startup : Error But php_mysql.dll file actually is in C:\Prog\SERVER\PHP\ext folder in my computer. How can I change this incorrect setting?
Advertisement
Don't use an absolute path when loading the extensions. Let it find them in its extensions directory.

You must only use extensions shipped with that build of PHP (Or built with it if you built it yourself). PHP's extensions ABI is not compatible between different builds (even the same version).

Mark
Quote:Original post by markr
Don't use an absolute path when loading the extensions. Let it find them in its extensions directory.

I didn't change any path setting. That's what I am asking, how to "change" it. I only included "bin" directory of MySQL into Path variable.

This error message started to pop up after I removed the semicolon at the beginning of the "extension=php_mysql.dll" line in PHP.ini like below :
...;extension=php_java.dll;extension=php_ldap.dll;extension=php_mcrypt.dll;extension=php_mhash.dll;extension=php_mime_magic.dll;extension=php_ming.dll;extension=php_mssql.dll;extension=php_msql.dllextension=php_mysql.dll;extension=php_oci8.dll;extension=php_openssl.dll;extension=php_oracle.dll;extension=php_pdf.dll;extension=php_pgsql.dll;extension=php_shmop.dll;extension=php_snmp.dll;extension=php_sockets.dll;extension=php_sybase_ct.dll...


Or you mean, you suggest me to use something like this? :
extension=C:\Porg\SERVER\PHP\ext\php_mysql.dll
This time it gave the following error :


Now what?!
Put the line:
extension_dir = "C:\Prog\SERVER\PHP\ext"
somewhere before the list of extensions. Then remove the path from the extension variable as before, so that it reads:
extension=php_mysql.dll
Quote:Original post by DaBono
Put the line:
extension_dir = "C:\Prog\SERVER\PHP\ext"
somewhere before the list of extensions. Then remove the path from the extension variable as before, so that it reads:
extension=php_mysql.dll
It worked.

But there's a new error now...


I don't know what to do. I'm totally stuck. I use the original library files which came with the installation pack. MySQL is working without any problem from the command line. "bin" directories are included into path. Copied libmysql.dll to c:\windows\system.

What's could be wrong with it?

[Edited by - Battousai on June 24, 2007 7:04:31 AM]

This topic is closed to new replies.

Advertisement