本文整理匯總了PHP中http::get_response_body方法的典型用法代碼示例。如果您正苦於以下問題:PHP http::get_response_body方法的具體用法?PHP http::get_response_body怎麽用?PHP http::get_response_body使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類http
的用法示例。
在下文中一共展示了http::get_response_body方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: _callWeboctave
private function _callWeboctave()
{
$form = array('commands' => $this->_script);
$http_client = new http(HTTP_V11, true);
$http_client->host = 'hara.mimuw.edu.pl';
$status = $http_client->post('/weboctave/web/index.php#menus', $form);
$this->_octaveResult = $http_client->get_response_body();
$http_client->disconnect();
unset($http_client);
$dom = new Weboctave_htmldom($this->_octaveResult);
return $dom->getOctaveResult($this->_iterations);
}
示例2: array
<?php
require_once 'http.inc';
header('Content-Type: text/plain');
$form = array('value' => 1, 'date' => '05/20/02', 'date_fmt' => 'us', 'result' => 1, 'lang' => 'eng', 'exch' => 'USD', 'Currency' => 'EUR', 'format' => 'HTML', 'script' => '../convert/fxdaily', 'dest' => 'Get Table');
$http_client = new http(HTTP_V11, true);
$http_client->host = 'www.oanda.com';
$status = $http_client->post('/convert/fxdaily', $form, 'http://www.oanda.com/convert/fxdaily');
if ($status == HTTP_STATUS_OK) {
print $http_client->get_response_body();
} else {
print "An error occured while requesting your file !\n";
print_r($http_client);
}
$http_client->disconnect();
unset($http_client);