4 include_once
'./Services/WebServices/ECS/classes/class.ilECSConnector.php';
5 include_once
'./Services/WebServices/ECS/classes/class.ilECSConnectorException.php';
30 public function getCourse($course_id,$a_details =
false)
32 $this->path_postfix =
'/campusconnect/courses/'. (int) $course_id;
34 if($a_details and $course_id)
36 $this->path_postfix .=
'/details';
44 $this->
addHeader(
'Accept',
'application/json');
48 $this->
addHeader(
'Accept',
'text/uri-list');
50 $this->curl->setOpt(CURLOPT_HTTPHEADER, $this->
getHeader());
53 if(substr(
$res, 0, 4) ==
'http')
55 $json = file_get_contents(
$res);
67 include_once
'./Services/WebServices/ECS/classes/class.ilECSEContentDetails.php';
69 $details->loadFromJson($ecs_result->getResult());
73 return $ecs_result->getResult();