1

While writing my registration code, I am using the command:

$ch = curl_init();

but am getting the following error:

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

Tried Installing curl on ubuntu using

sudo apt-get install php-curl

but am getting the following

Reading package lists... Done Building dependency tree Reading state information... Done php-curl is already the newest version (1:7.2+62+ubuntu17.10.1+deb.sury.org+1). 0 upgraded, 0 newly installed, 0 to remove and 154 not upgraded. 2 not fully installed or removed. After this operation, 0 B of additional disk space will be used. Do you want to continue? [Y/n] Y Setting up mysql-server-5.7 (5.7.22-0ubuntu0.17.10.1) ... Checking if update is needed. Checking server version. Running queries to upgrade MySQL server. mysql_upgrade: [ERROR] 1136: Column count doesn't match value count at row 1 mysql_upgrade failed with exit status 5 dpkg: error processing package mysql-server-5.7 (--configure): subprocess installed post-installation script returned error exit status 1 dpkg: dependency problems prevent configuration of mysql-server: mysql-server depends on mysql-server-5.7; however: Package mysql-server-5.7 is not configured yet.

dpkg: error processing package mysql-server (--configure): dependency problems - leaving unconfigured No apport report written because the error message indicates its a followup error from a previous failure. Errors were encountered while processing: mysql-server-5.7 mysql-server E: Sub-process /usr/bin/dpkg returned an error code (1)

What should I do?

Tried restarting apache anyway but that doesn't work either I also tried all suggestions as per How to install php-curl in Ubuntu 16.04 Nothing is working.

Rachel Watson
  • 212
  • 2
  • 9

0 Answers0