my ($headers, $body) = ('',''); use WWW::Curl::easy; my $curl = WWW::Curl::easy->new(); my $CURLcode = $curl->setopt(CURLOPT_WRITEFUNCTION, \&callback); $CURLcode = WWW::Curl::easy::setopt($curl, CURLOPT_URL, $broker_ur +l); $CURLcode .= WWW::Curl::easy::setopt($curl, CURLOPT_HEADER,\$heade +rs); $CURLcode .= WWW::Curl::easy::setopt($curl, CURLOPT_POSTFIELDS, $p +ost_vars); $CURLcode .= WWW::Curl::easy::perform($curl); WWW::Curl::easy::cleanup($curl);
sub callback { my ($data,$pointer)=@_; $params{'data'} .= $data; return length($data); }
HTTP/1.1 200 OK Date: Mon, 14 Mar 2005 01:42:55 GMT Server: Apache/2.0.40 (Red Hat Linux) Accept-Ranges: bytes X-Powered-By: PHP/4.2.2 Connection: close Transfer-Encoding: chunked Content-Type: text/html; charset=ISO-8859-1
In reply to Unwanted output to STDOUT in WWW::Curl::new by snookmz
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |