I tried to install the CURL in my server but failed. My server is running in Ubuntu 18.04 LTS & PHP 7.2 version. I used the command to install the CURL in my server.
The command I used:
sudo apt-get install curlsudo service apache2 restartI restart my server using this commandsudo apt-get install php7.2-curlsudo service apache2 restartAgain I restarted my server.
But after this nothing works. The CURL Command is not executing.
curl
The output is nothing, Is there any way to install the CURL which is compatible with PHP7.2 version.
12 Answers
Need to use the following commands:
sudo add-apt-repository ppa:ondrej/phpsudo apt updatesudo apt install php7.2-fpm php7.2-gd php7.2-curl php7.2-mysql php7.2-dev php7.2-cli php7.2-common php7.2-mbstring php7.2-intl php7.2-zip php7.2-bcmath
Then need to restart my server.
I tried this and it worked for me!
$ sudo apt-get install curl
$ sudo apt update
$ sudo add-apt-repository ppa:ondrej/php
$ sudo apt install php7.2-curl php7.2-mysql php7.2-dev php7.2-cli php7.2-intl
$ sudo service apache2 restart