本文整理汇总了PHP中Evaluation::get_category_id方法的典型用法代码示例。如果您正苦于以下问题:PHP Evaluation::get_category_id方法的具体用法?PHP Evaluation::get_category_id怎么用?PHP Evaluation::get_category_id使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Evaluation
的用法示例。
在下文中一共展示了Evaluation::get_category_id方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: header
$eval->set_weight($values['weight']);
$eval->set_max($values['max']);
if (empty($values['visible'])) {
$visible = 0;
} else {
$visible = 1;
}
$eval->set_visible($visible);
$eval->add();
if ($eval->get_course_code() == null) {
if ($values['adduser'] == 1) {
//Disabling code when course code is null see issue #2705
//header('Location: gradebook_add_user.php?selecteval=' . $eval->get_id());
exit;
} else {
header('Location: ' . Security::remove_XSS($_SESSION['gradebook_dest']) . '?selectcat=' . $eval->get_category_id() . '&' . api_get_cidreq());
exit;
}
} else {
$val_addresult = isset($values['addresult']) ? $values['addresult'] : null;
if ($val_addresult == 1) {
header('Location: gradebook_add_result.php?selecteval=' . $eval->get_id() . '&' . api_get_cidreq());
exit;
} else {
header('Location: ' . Security::remove_XSS($_SESSION['gradebook_dest']) . '?selectcat=' . $eval->get_category_id() . '&' . api_get_cidreq());
exit;
}
}
}
$interbreadcrumb[] = array('url' => Security::remove_XSS($_SESSION['gradebook_dest']) . '?selectcat=' . $select_cat . '&' . api_get_cidreq(), 'name' => get_lang('Gradebook'));
$this_section = SECTION_COURSES;
示例2: header
$eval->set_description($values['description']);
$eval->set_user_id($values['hid_user_id']);
$eval->set_course_code($values['hid_course_code']);
$eval->set_category_id($values['hid_category_id']);
$parent_cat = Category::load($values['hid_category_id']);
$final_weight = $values['weight_mask'];
$eval->set_weight($final_weight);
$eval->set_max($values['max']);
if (empty($values['visible'])) {
$visible = 0;
} else {
$visible = 1;
}
$eval->set_visible($visible);
$eval->save();
header('Location: ' . $_SESSION['gradebook_dest'] . '?editeval=&selectcat=' . $eval->get_category_id());
exit;
}
$selectcat_inter = isset($_GET['selectcat']) ? Security::remove_XSS($_GET['selectcat']) : '';
$interbreadcrumb[] = array('url' => $_SESSION['gradebook_dest'] . '?selectcat=' . $selectcat_inter, 'name' => get_lang('Gradebook'));
$htmlHeadXtra[] = '<script type="text/javascript">
$(document).ready( function() {
$("#hid_category_id").change(function() {
$("#hid_category_id option:selected").each(function () {
var cat_id = $(this).val();
$.ajax({
url: "' . api_get_path(WEB_AJAX_PATH) . 'gradebook.ajax.php?a=get_gradebook_weight",
data: "cat_id="+cat_id,
success: function(return_value) {
if (return_value != 0 ) {
$("#max_weight").html(return_value);