/** * Returns a list with the instructors for the provided course * or a message indicating there are none. * * @since 0.1 * * @param EPCourse $course * * @return string */ protected function getInstructorsList(EPCourse $course) { $instructors = $course->getInstructors(); if (count($instructors) > 0) { $instList = array(); foreach ($instructors as $instructor) { $instList[] = $instructor->getUserLink() . $instructor->getToolLinks($this->getContext(), $course); } if (count($instructors) == 1) { return $instList[0]; } else { return '<ul><li>' . implode('</li><li>', $instList) . '</li></ul>'; } } else { return wfMsgHtml('ep-course-no-instructors'); } }