Answers for "does php curl need to be installed"

PHP
1

how to install php curl (linux) apache2

#install the latest php CURL
sudo apt-get install php-curl

#install a specific PHP[version]-curl, php version 5 is the example below
sudo apt-get install php5-curl

#restart apache by typing
sudo service apache2
Posted by: Guest on September-23-2021
2

php curl example

function getUrl($url){
    $ch = curl_init($url);
    curl_setopt($ch, CURLOPT_RETURNTRANSFER, TRUE);
    $response = curl_exec($ch);
    curl_close($ch);
    return $response;
}
Posted by: Guest on June-26-2019

Code answers related to "does php curl need to be installed"

Browse Popular Code Answers by Language