PHP - Solve the problem that curl extension cannot be opened

高洛峰
Release: 2016-11-17 11:39:58
Original
1538 people have browsed it

1. Problem

Recently, a PHP environment (64-bit Win7 system, Apache24, PHP5.6) was built locally to debug the program. Since the page needs to use curl, the relevant configurations in php.ini are modified.

extension=php_curl.dll
 
extension_dir = "G:/php/ext"
Copy after login

But after restarting Apache, there is still no curl_init function error (Fatal error: Call to undefined function curl_init() in xxxxxx). Use phpinfo() to check and find that the curl function is not turned on.

PHP - Solve the problem that curl extension cannot be opened

2, Problem Solved

(1) Copy the four files libeay32.dll, ssleay32.dll, libssh2.dll in the php directory and php_curl.dll in the ext directory to the C:WindowsSystem32 directory Down.

(2) Restart Apache, and then use the phpinfo() function to check that curl has been successfully enabled.

PHP - Solve the problem that curl extension cannot be opened

Related labels:
php
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!