本文整理汇总了PHP中EfrontLesson::getUnits方法的典型用法代码示例。如果您正苦于以下问题:PHP EfrontLesson::getUnits方法的具体用法?PHP EfrontLesson::getUnits怎么用?PHP EfrontLesson::getUnits使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类EfrontLesson
的用法示例。
在下文中一共展示了EfrontLesson::getUnits方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: EfrontLesson
}
break;
case 'lesson_info':
if (isset($_GET['token']) && checkToken($_GET['token'])) {
if (isset($_GET['lesson'])) {
if (eF_checkParameter($_GET['lesson'], 'id') == false) {
echo "<xml>";
echo "<status>error</status>";
echo "<message>Invalid lesson id</message>";
echo "</xml>";
exit;
}
try {
$lesson = new EfrontLesson($_GET['lesson']);
$users = $lesson->getUsers('professor');
$content = $lesson->getUnits();
$info = $lesson->getStatisticInformation();
$lesson_info = unserialize($lesson->lesson['info']);
$metadata = unserialize($lesson->lesson['metadata']);
echo "<xml>";
echo "<general_info>";
echo "<name>" . $lesson->lesson['name'] . "</name>";
echo "<direction>" . $lesson->lesson['directions_ID'] . "</direction>";
echo "<price>";
echo "<value>" . $info['price'] . "</value>";
echo "<currency>" . $GLOBALS['configuration']['currency'] . "</currency>";
echo "</price>";
echo "<language>" . $info['language'] . "</language>";
echo "<info>";
foreach ($lesson_info as $key => $value) {
echo "<" . $key . ">" . $value . "</" . $key . ">";