I have spent several hours trying to figure out why Phpmyadmin doesn't work with a PHP version other than 5.3. I tried on two Macs with the same result.
The error I get when I enable PHP 5.4, 5.5 or 5.6 when going to PhpMyAdmin is: "The mysqli|mysql extension is missing. Please check your PHP configuration. See our documentation for more information." The help link refers me to /phpmyadmin/doc/html/faq.html#faqmysql but this isn't helpful because the packages are enabled, it just cannot find libmysqlclient.18.dylib. When I go to /cgi-bin/phpinfo.cgi at the bottom of this "PHP Info" page I get:
Quote
Warning: PHP Startup: Unable to load dynamic library '/Applications/AMPPS/php-5.6/lib/extensions/ext/mysqli.so' - dlopen(/Applications/AMPPS/php-5.6/lib/extensions/ext/mysqli.so, 9): Library not loaded: libmysqlclient.18.dylib Referenced from: /Applications/AMPPS/php-5.6/lib/extensions/ext/mysqli.so Reason: image not found in Unknown on line 0
Warning: PHP Startup: Unable to load dynamic library '/Applications/AMPPS/php-5.6/lib/extensions/ext/pdo_mysql.so' - dlopen(/Applications/AMPPS/php-5.6/lib/extensions/ext/pdo_mysql.so, 9): Library not loaded: libmysqlclient.18.dylib Referenced from: /Applications/AMPPS/php-5.6/lib/extensions/ext/pdo_mysql.so Reason: image not found in Unknown on line 0
Warning: PHP Startup: Unable to load dynamic library '/Applications/AMPPS/php-5.6/lib/extensions/ext/mysql.so' - dlopen(/Applications/AMPPS/php-5.6/lib/extensions/ext/mysql.so, 9): Library not loaded: libmysqlclient.18.dylib Referenced from: /Applications/AMPPS/php-5.6/lib/extensions/ext/mysql.so Reason: image not found in Unknown on line 0
However, when I run these commands via the command line to see if mysql loads OK it does!
PHP Code ➜ AMPPS pwd
/Applications/AMPPS
➜ AMPPS php-5.6/bin/php -r 'if (extension_loaded("mysqli")) { print_r("loaded"); }'
loaded%
I suspect this is a problem with Apache and it's not running PHP with the right arguments or something or using a totally different PHP than the one in AMPPS.
How can I troubleshoot this further?
|