Home >Backend Development >PHP Problem >What should I do if php does not have the mysql module?
The solution to the problem that php does not have the mysql module: first open the php.ini configuration file; then add the code as "extension_dir="D:\php5_6\ext""; finally save the changes.
Recommended: "PHP Video Tutorial"
Record once to solve phpinfo() without mysql module Question
I had a sudden idea and planned to review ThinkPHP5, but I got stuck before I started. There was a problem when connecting to the database.
Error message
I searched on Baidu first, and it was said online that the mysql module was not loaded in php.ini when configuring PHP, but I opened it The php.ini file sees that extension=php_mysql.dll is open.
But I used the phpinfo() function to check that there is still no mysql module. I looked at the path of Loaded Configuration File and it was correct, but I was helpless in the end. With the intention of giving it a try, I forcefully added this line to the php.ini file:
Change location
In the end, the error was successfully eliminated!
The above is the detailed content of What should I do if php does not have the mysql module?. For more information, please follow other related articles on the PHP Chinese website!