我也得到了宁静的Web服务响应。但我不能够正确地解析它RESTful Web服务响应解析问题
我的代码看起来像这样
include 'RestClient.class.php';
error_reporting(E_ALL);
// Client Profile
$url = "http://localhost/lgen/index.php/api/client";
$ex = RestClient::get($url,array('requestType' =>'viewClientProfile',
'username' => 'uname',
'pass' =>'pass'));
echo $response = $ex->getResponse();
$xml = simplexml_load_string($response);
当打印$回应我得到浏览器的数据,但在试图解析它我没有得到任何类型的数据
的
有啥问题?你有没有得到任何错误? – Simone
当打印$回应我得到浏览器的数据,但在试图解析它我没有得到任何类型的数据 – sree