如何在xampp中启用curl? [英] How to enable curl in xampp?
问题描述
如何在xampp中启用curl?
How to enable curl in xampp ?
我的PHP twitter应用程序需要curl函数。但它没有在XAMPP中启用。如何启用它。我找不到这样做的选项。
My PHP twitter application needs curl function. But it is not enabled in XAMPP. how to enable it. I found no options for doing that.
推荐答案
您必须修改xampp文件夹中的php.ini文件。
You have to modify the php.ini files in your xampp folder. Three files in three different places need to be changed.
按照以下步骤在Windows中启用curl library with XAMPP:
Follow the following steps to enable curl library with XAMPP in Windows:
浏览并开启以下3个档案
Browse and open the following 3 files
C:\Program Files\xampp\apache\bin\php.ini
C:\Program Files\xampp\php\php.ini
C:\Program Files\xampp\php\php4\php.ini
步骤2:
通过删除分号(;),取消注释php.ini文件中的以下行。
Step 2:
Uncomment the following line in your php.ini file by removing the semicolon (;).
;extension=php_curl.dll
以下 -
extension=php_curl.dll
步骤3:
重新启动您的Apache伺服器。
Step 3:
Restart your Apache server.
检查您的 phpinfo()
,看看curl是否已正确启用。
Check your phpinfo()
to see whether curl has properly enabled or not.
使用curl()库。
这篇关于如何在xampp中启用curl?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!