当前位置: 首页>>代码示例>>PHP>>正文


PHP ExerciseLib::display_question_list_by_attempt方法代码示例

本文整理汇总了PHP中ExerciseLib::display_question_list_by_attempt方法的典型用法代码示例。如果您正苦于以下问题:PHP ExerciseLib::display_question_list_by_attempt方法的具体用法?PHP ExerciseLib::display_question_list_by_attempt怎么用?PHP ExerciseLib::display_question_list_by_attempt使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在ExerciseLib的用法示例。


在下文中一共展示了ExerciseLib::display_question_list_by_attempt方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: array

        Display::display_warning_message(sprintf(get_lang('ReachedMaxAttempts'), $objExercise->selectTitle(), $objExercise->selectAttempts()), false);
        if ($origin != 'learnpath') {
            //we are not in learnpath tool
            Display::display_footer();
        }
        exit;
    }
}
$total_score = 0;
if (!empty($exercise_stat_info)) {
    $total_score = $exercise_stat_info['exe_result'];
}
$max_score = $objExercise->get_max_score();
Display::display_normal_message(get_lang('Saved') . '<br />', false);
// Display and save questions
ExerciseLib::display_question_list_by_attempt($objExercise, $exe_id, true);
//Unset session for clock time
ExerciseLib::exercise_time_control_delete($objExercise->id, $learnpath_id, $learnpath_item_id);
ExerciseLib::delete_chat_exercise_session($exe_id);
if ($origin != 'learnpath') {
    echo '<hr>';
    echo Display::url(get_lang('ReturnToCourseHomepage'), api_get_course_url(), array('class' => 'btn btn-primary'));
    if (api_is_allowed_to_session_edit()) {
        Session::erase('objExercise');
        Session::erase('exe_id');
    }
    Display::display_footer();
} else {
    $lp_mode = Session::read('lp_mode');
    $url = '../newscorm/lp_controller.php?cidReq=' . api_get_course_id() . '&action=view&lp_id=' . $learnpath_id . '&lp_item_id=' . $learnpath_item_id . '&exeId=' . $exercise_stat_info['exe_id'] . '&fb_type=' . $objExercise->feedback_type;
    $href = $lp_mode == 'fullscreen' ? ' window.opener.location.href="' . $url . '" ' : ' top.location.href="' . $url . '"';
开发者ID:omaoibrahim,项目名称:chamilo-lms,代码行数:31,代码来源:exercise_result.php

示例2: api_not_allowed

if (empty($track_exercise_info)) {
    api_not_allowed($show_headers);
}
$exercise_id = $track_exercise_info['exe_exo_id'];
$student_id = $track_exercise_info['exe_user_id'];
$current_user_id = api_get_user_id();
$objExercise = new Exercise();
if (!empty($exercise_id)) {
    $objExercise->read($exercise_id);
}
// Only users can see their own results
if (!$is_allowedToEdit) {
    if ($student_id != $current_user_id) {
        api_not_allowed($show_headers);
    }
}
$htmlHeadXtra[] = '<link rel="stylesheet" href="' . api_get_path(WEB_LIBRARY_JS_PATH) . 'hotspot/css/hotspot.css">';
$htmlHeadXtra[] = '<script src="' . api_get_path(WEB_LIBRARY_JS_PATH) . 'hotspot/js/hotspot.js"></script>';
if ($show_headers) {
    $interbreadcrumb[] = array("url" => "exercise.php?" . api_get_cidreq(), "name" => get_lang('Exercises'));
    $interbreadcrumb[] = array("url" => "#", "name" => get_lang('Result'));
    $this_section = SECTION_COURSES;
    Display::display_header();
} else {
    $htmlHeadXtra[] = "\n    <style>\n    body { background: none;}\n    </style>\n    ";
    Display::display_reduced_header();
}
ExerciseLib::display_question_list_by_attempt($objExercise, $id, false);
if ($show_headers) {
    Display::display_footer();
}
开发者ID:omaoibrahim,项目名称:chamilo-lms,代码行数:31,代码来源:result.php


注:本文中的ExerciseLib::display_question_list_by_attempt方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。