Difference between revisions of "PHP/cURL"

from HTYP, the free directory anyone can edit if they can prove to me that they're not a spambot
< PHP
Jump to: navigation, search
(Created page with "==About== This page is about using cURL within PHP. ==Setup - Notes== Getting cURL set up can be easy or not-easy, depending on various factors. I'm still trying to fi...")
 
 
Line 1: Line 1:
 
==About==
 
==About==
 
This page is about using [[cURL]] within [[PHP]].
 
This page is about using [[cURL]] within [[PHP]].
==Setup - Notes==
+
==Setup - Woozle Notes==
Getting cURL set up can be easy or not-easy, depending on various factors. I'm still trying to figure out why it apparently isn't working on cloud5. Tentatively, the problem is that PHP is running v7.0 instead of v7.2 (via [[FastCGI]]), and there is no libcurl package for PHP 7.0.
+
Getting cURL set up can be easy or not-easy, depending on various factors. I'm still trying to figure out why it apparently isn't working on cloud5. Tentatively, the problem is that PHP is running v7.0 instead of v7.2 (via [[FastCGI]]), and there is no libcurl package for PHP 7.0. I ultimately solved the problem by changing how PHP is invoked &ndash; from FastCGI, which seems to be stuck on 7.0 (and I don't know where it is configured) to directly invoking PHP 7.2 via CGI-BIN: <code>/cgi-bin/php7.2.cgi</code>
  
 
PHP 5 instructions:
 
PHP 5 instructions:
 
* '''2014-05-21''' [https://www.digitalocean.com/community/questions/curl-is-not-installed-in-your-php-installation cURL is NOT installed in your PHP installation?]
 
* '''2014-05-21''' [https://www.digitalocean.com/community/questions/curl-is-not-installed-in-your-php-installation cURL is NOT installed in your PHP installation?]
 
* (undated) [https://gistpages.com/posts/how_to_install_curl_for_php_in_ubuntu How to Install curl for PHP in Ubuntu]: includes PHP 7 instructions, but they don't work ("Package php7.0-curl is not available, but is referred to by another package.")
 
* (undated) [https://gistpages.com/posts/how_to_install_curl_for_php_in_ubuntu How to Install curl for PHP in Ubuntu]: includes PHP 7 instructions, but they don't work ("Package php7.0-curl is not available, but is referred to by another package.")

Latest revision as of 16:27, 12 October 2019

About

This page is about using cURL within PHP.

Setup - Woozle Notes

Getting cURL set up can be easy or not-easy, depending on various factors. I'm still trying to figure out why it apparently isn't working on cloud5. Tentatively, the problem is that PHP is running v7.0 instead of v7.2 (via FastCGI), and there is no libcurl package for PHP 7.0. I ultimately solved the problem by changing how PHP is invoked – from FastCGI, which seems to be stuck on 7.0 (and I don't know where it is configured) to directly invoking PHP 7.2 via CGI-BIN: /cgi-bin/php7.2.cgi

PHP 5 instructions: