PHP Fatal error: Uncaught Error: Call to undefined function curl_init()

mateusz

Verified User
Joined
Mar 19, 2020
Messages
11
Hey,

I have a problem, and I'm stuck.

I'm trying to use a code: https://github.com/ClouDNS/cloudns-...ave-zones-add/directadmin-slave-zones-add.php
But I'm getting:

PHP Fatal error: Uncaught Error: Call to undefined function curl_init() in /directadmin-slave-zones-add.php:26

I have used Build software in CustomBuild 2.0 - it's enabled
Screenshot 2022-04-13 at 16.15.09.png


Rebooted the server, but still nothing... any ideas?


Thanks for your help!
Mat
 
Your screenshot shows curl is enabled but is the curl module enabled in php? Check with

Code:
php -m |grep -i curl

If not, you need to recompile php with the curl module.
 
Your screenshot shows curl is enabled but is the curl module enabled in php? Check with

Code:
php -m |grep -i curl

If not, you need to recompile php with the curl module.
Thanks, I get "curl" - any ideas?
 
Do you have multiple PHP versions installed? Is the curl extension enabled on all of them?
 
Thanks.
Now I see something different... :-(
PHP Warning: PHP Startup: Unable to load dynamic library 'curl' (tried: /usr/lib/php/20180731/curl (/usr/lib/php/20180731/curl: cannot open shared object file: No such file or directory), /usr/lib/php/20180731/curl.so (/usr/lib/php/20180731/curl.so: cannot open shared object file: No such file or directory)) in Unknown on line 0
PHP Fatal error: Uncaught Error: Call to undefined function curl_init() in /directadmin-slave-zones-add.php:26
Stack trace:
#0 /directadmin-slave-zones-add.php(38): apiCall('https://api.clo...', 'auth-id=4088&au...')
#1 {main}
thrown in /directadmin-slave-zones-add.php on line 26
 
Back
Top