Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/php/246.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/variables/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Php cUrl到perl FCGI脚本_Php_Perl_Curl_Fastcgi_Lwp - Fatal编程技术网

Php cUrl到perl FCGI脚本

Php cUrl到perl FCGI脚本,php,perl,curl,fastcgi,lwp,Php,Perl,Curl,Fastcgi,Lwp,我必须用php重新创建现有代码 实现FCGI::Request()的perl脚本通过LWP::UserAgent->credentials()连接到 如何使用cUrl(php)而不是LWP(perl)连接到此脚本? 或者,有什么更好/更适合的方法从php连接到这样的服务器 curl_setopt($ch, CURLOPT_USERPWD, urlencode($username) . ':' . urlencode($password)); 其中,$ch是$ch=curl_init()Rest

我必须用php重新创建现有代码

实现
FCGI::Request()
的perl脚本通过
LWP::UserAgent->credentials()连接到

如何使用cUrl(php)而不是LWP(perl)连接到此脚本?
或者,有什么更好/更适合的方法从php连接到这样的服务器

curl_setopt($ch, CURLOPT_USERPWD, urlencode($username) . ':' . urlencode($password));
其中,$ch是
$ch=curl_init()Rest是不言自明的

另请参见:和。

注意。->credentials()调用USer&pass,加上'realm'。