php cannot load the extension solution: 1. Enable "extension=php_curl.dll" in php.ini; 2. Configure ""D:/webserver/php in Apache's httpd.conf file /ssleay32.dll"" is enough.
#The operating environment of this article: Windows7 system, PHP7.1, Dell G3 computer.
Solve the problem of PHP extension not loading:
Method 1 (passed the test) has built-in php_curl.dll. In the ext directory, this DLL is used to support SSL and zlib.
1. Find extension=php_curl.dll in php.ini, remove the previous comment.
2. Set extension_dir=c:\php\ext, refresh the PHP page An error was reported, saying that the module php_curl.dll could not be found.
Copy php_curl.dll to windows\system32, still the same error.
3. I searched online and needed to change:
libeay32.dll, ssleay32.dll, php5ts.dll, php_curl.dll
Copy them all to the system32 directory and restart apache.
Method 2 can also be tried :
1. This php_curl.dll depends on two files (ssleay32.dll and libeay32.dll). If these two files are not configured correctly, it will prompt that the dynamic library cannot be found. These two files Under the php directory.
2. Solution: Configure it in Apache’s httpd.conf file:
LoadFile "D:/webserver/php/ssleay32.dll" LoadFile "D:/webserver/php/libeay32.dll"
3. Then restart the apache service and it will be ok.
[Recommended: "PHP Video Tutorial"]
The above is the detailed content of What should I do if php cannot load the extension?. For more information, please follow other related articles on the PHP Chinese website!