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


PHP Util::jump_to方法代码示例

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


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

示例1: getOp

 function getOp()
 {
     $res = "main";
     $op = importVar("sel_op");
     $manual = $this->onManualSelector();
     if ($manual) {
         $res = isset($_GET["stayon"]) ? "manual" : "manual_init";
     }
     if (isset($_POST["orgchartselector"])) {
         $res = 'orgchartselector';
     }
     if (isset($_POST['okselector_org'])) {
         return 'save_org';
     }
     if (isset($_POST["okselector"]) && !$manual) {
         $res = "save";
     } else {
         if (isset($_POST["okselector"]) && $manual) {
             $res = "save_manual";
         } else {
             if (isset($_POST["cancelselector"]) && !$manual) {
                 Util::jump_to($this->getLink("back", "", true));
             } else {
                 if (isset($_POST["cancelselector"]) && $manual) {
                     Util::jump_to($this->getLink("main", "", true));
                 }
             }
         }
     }
     return $res;
 }
开发者ID:abhinay100,项目名称:forma_app,代码行数:31,代码来源:lib.simplesel.php

示例2: loadBody

 function loadBody()
 {
     switch ($GLOBALS['op']) {
         case 'showresults':
             $id_course = Get::req('id_course', DOTY_INT, false);
             $_SESSION['idCourse'] = $id_course;
             Util::jump_to('index.php?modname=organization&op=showresults&idcourse=' . $id_course);
             break;
         case "mycourses":
         case "unregistercourse":
             require_once $GLOBALS['where_lms'] . '/modules/' . $this->module_name . '/course.php';
             require_once _base_ . '/lib/lib.urlmanager.php';
             $url =& UrlManager::getInstance('course');
             $url->setStdQuery('r=' . _after_login_);
             mycourses($url);
             break;
         case "donwloadmaterials":
             downloadMaterials();
             break;
         default:
             require_once $GLOBALS['where_lms'] . '/modules/' . $this->module_name . '/infocourse.php';
             infocourseDispatch($GLOBALS['op']);
             break;
     }
 }
开发者ID:abhinay100,项目名称:forma_app,代码行数:25,代码来源:class.course.php

示例3: edithtml

function edithtml()
{
    checkPerm('mod');
    require_once _base_ . '/lib/lib.form.php';
    $query = "\r\n\tSELECT textof\r\n\tFROM " . $GLOBALS['prefix_lms'] . "_htmlfront \r\n\tWHERE id_course = '" . $_SESSION['idCourse'] . "'";
    $re_htmlfront = sql_query($query);
    $error = false;
    if (isset($_POST['save'])) {
        if (mysql_num_rows($re_htmlfront) > 0) {
            $upd_query = "\r\n\t\t\tUPDATE " . $GLOBALS['prefix_lms'] . "_htmlfront \r\n\t\t\tSET textof = '" . $_POST['description'] . "'\r\n\t\t\tWHERE id_course = '" . $_SESSION['idCourse'] . "'";
            $re = sql_query($upd_query);
        } else {
            $ins_query = "\r\n\t\t\tINSERT INTO " . $GLOBALS['prefix_lms'] . "_htmlfront \r\n\t\t\t( id_course, textof) VALUES \r\n\t\t\t( \t'" . $_SESSION['idCourse'] . "',\r\n\t\t\t\t'" . $_POST['description'] . "' )";
            $re = sql_query($ins_query);
        }
        if ($re) {
            Util::jump_to('index.php?modname=htmlfront&op=showhtml&saveok=1');
        } else {
            $error = true;
        }
    }
    $lang =& DoceboLanguage::createInstance('htmlfront', 'lms');
    list($textof) = sql_fetch_row($re_htmlfront);
    $title_page = array('index.php?modname=htmlfront&op=showhtml' => $lang->def('_HTMLFRONT'), $lang->def('_MOD'));
    $GLOBALS['page']->add(getTitleArea($title_page, 'htmlfront') . '<div class="std_block">' . getBackUi('index.php?modname=htmlfront&amp;op=showhtml', $lang->def('_BACK')) . ($error ? getErrorUi($lang->def('_ERROR_IN_SAVE')) : '') . Form::openForm('formnotes', 'index.php?modname=htmlfront&amp;op=edithtml') . Form::openElementSpace() . Form::getTextarea($lang->def('_TEXTOF'), 'description', 'description', importVar('description', false, $textof)) . Form::closeElementSpace() . Form::openButtonSpace() . Form::getButton('save', 'save', $lang->def('_SAVE')) . Form::getButton('undo', 'undo', $lang->def('_UNDO')) . Form::closeButtonSpace() . Form::closeForm() . '</div>', 'content');
}
开发者ID:abhinay100,项目名称:forma_app,代码行数:26,代码来源:htmlfront.php

示例4: mod

 public function mod()
 {
     $id_trans = Get::req('id_trans', DOTY_INT, 0);
     if (isset($_POST['undo'])) {
         Util::jump_to('index.php?r=alms/transaction/show');
     }
     if (isset($_POST['save']) || isset($_POST['not_paid'])) {
         $product_to_activate = Get::req('product', DOTY_MIXED, array());
         $id_user = Get::req('id_user', DOTY_MIXED, 0);
         if ($this->model->saveTransaction($product_to_activate, $id_trans, $id_user)) {
             $this->model->controlActivation($id_trans, isset($_POST['not_paid']));
             Util::jump_to('index.php?r=alms/transaction/show&res=ok');
         }
         Util::jump_to('index.php?r=alms/transaction/show&res=err');
     }
     $transaction_info = $this->model->getTransactionInfo($id_trans);
     $user_info = $this->acl_man->getUser($transaction_info['id_user'], false);
     $user_info[ACL_INFO_USERID] = $this->acl_man->relativeId($user_info[ACL_INFO_USERID]);
     require_once _base_ . '/lib/lib.table.php';
     $tb = new Table(false, Lang::t('_DETAILS', 'transaction'), Lang::t('_DETAILS', 'transaction'));
     $ts = array('', '', 'min-cell', 'image');
     $th = array(Lang::t('_CODE', 'transaction'), Lang::t('_NAME', 'transaction'), Lang::t('_PRICE', 'transaction'), Lang::t('_MARK_AS_PAID', 'transaction'));
     $tb->setColsStyle($ts);
     $tb->addHead($th);
     foreach ($transaction_info['product'] as $product_info) {
         $tb->addBody(array($product_info['code'], $product_info['name'], $product_info['price'], Form::getInputCheckbox('product_' . $product_info['id_course'] . '_' . $product_info['id_date'] . '_' . $product_info['id_edition'], 'product[' . $product_info['id_course'] . '_' . $product_info['id_date'] . '_' . $product_info['id_edition'] . ']', 1, $product_info['activated'], $product_info['activated'] ? ' disabled="disabled"' : '')));
     }
     $this->render('mod', array('transaction_info' => $transaction_info, 'user_info' => $user_info, 'tb' => $tb, 'id_trans' => $id_trans));
 }
开发者ID:abhinay100,项目名称:forma_app,代码行数:29,代码来源:TransactionAlmsController.php

示例5: edit

 function edit($back_test)
 {
     $lang =& DoceboLanguage::createInstance('test');
     require_once _base_ . '/lib/lib.form.php';
     $url_encode = htmlentities(urlencode($back_test));
     if (isset($_POST['add_question'])) {
         if (!sql_query("\r\n\t\t\tUPDATE " . $GLOBALS['prefix_lms'] . "_testquest \r\n\t\t\tSET idCategory = '" . (int) $_POST['idCategory'] . "', \r\n\t\t\t\ttitle_quest = '" . $_POST['title_quest'] . "', \r\n\t\t\t\tdifficult = '" . (int) $_POST['difficult'] . "', \r\n\t\t\t\ttime_assigned = '" . (int) $_POST['time_assigned'] . "' \r\n\t\t\tWHERE idQuest = '" . $this->id . "'")) {
             errorCommunication($lang->def('_ERR_INS_QUEST') . getBackUi('index.php?modname=question&amp;op=edit&amp;type_quest=' . $this->getQuestionType() . '&amp;idQuest=' . $this->id . '&amp;back_test=' . $url_encode, $lang->def('_BACK')));
         }
         if (!sql_query("\r\n\t\t\tUPDATE " . $GLOBALS['prefix_lms'] . "_testquestanswer \r\n\t\t\tSET score_correct = '" . $this->_checkScore($_POST['max_score']) . "'\r\n\t\t\tWHERE idQuest = '" . $this->id . "'")) {
             errorCommunication($lang->def('_ERR_INS_QUEST') . getBackUi('index.php?modname=question&amp;op=edit&amp;type_quest=' . $this->getQuestionType() . '&amp;idQuest=' . $this->id . '&amp;back_test=' . $url_encode, $lang->def('_BACK')));
         }
         Util::jump_to('' . $back_test);
     }
     //finding categories
     require_once $GLOBALS['where_lms'] . '/lib/lib.questcategory.php';
     $categories = Questcategory::getCategory();
     //create array of difficult
     $arr_dufficult = array(5 => '5 - ' . $lang->def('_VERY_HARD'), 4 => '4 - ' . $lang->def('_HARD'), 3 => '3 - ' . $lang->def('_DIFFICULT_MEDIUM'), 2 => '2 - ' . $lang->def('_DIFFICULT_EASY'), 1 => '1 - ' . $lang->def('_DIFFICULT_VERYEASY'));
     list($title_quest, $cat_sel, $diff_sel, $sel_time) = sql_fetch_row(sql_query("\r\n\t\tSELECT title_quest, idCategory, difficult, time_assigned \r\n\t\tFROM " . $GLOBALS['prefix_lms'] . "_testquest \r\n\t\tWHERE idQuest = '" . $this->id . "'"));
     list($max_score) = sql_fetch_row(sql_query("\r\n\t\tSELECT score_correct\r\n\t\tFROM " . $GLOBALS['prefix_lms'] . "_testquestanswer \r\n\t\tWHERE idQuest = '" . $this->id . "'"));
     $GLOBALS['page']->add(getTitleArea($lang->def('_TEST_SECTION'), 'test') . '<div class="std_block">' . getBackUi(Util::str_replace_once('&', '&amp;', $back_test), $lang->def('_BACK')) . '<div class="title_big">' . $lang->def('_QUEST_ACRN_' . strtoupper($this->getQuestionType())) . ' - ' . $lang->def('_QUEST_' . strtoupper($this->getQuestionType())) . '</div><br />' . Form::openForm('form_mod_quest', 'index.php?modname=question&amp;op=edit') . Form::openElementSpace() . Form::getHidden('type_quest', 'type_quest', $this->getQuestionType()) . Form::getHidden('idQuest', 'idQuest', $this->id) . Form::getHidden('back_test', 'back_test', $url_encode) . Form::getTextarea($lang->def('_QUESTION'), 'title_quest', 'title_quest', $title_quest), 'content');
     if (count($categories) > 1) {
         $GLOBALS['page']->add(Form::getDropdown($lang->def('_TEST_QUEST_CATEGORY'), 'idCategory', 'idCategory', $categories, isset($_POST['idCategory']) ? $_POST['idCategory'] : $cat_sel), 'content');
     }
     $GLOBALS['page']->add(Form::getDropdown($lang->def('_DIFFICULTY'), 'difficult', 'difficult', $arr_dufficult, $diff_sel) . Form::getTextfield($lang->def('_TEST_QUEST_TIMEASS'), 'time_assigned', 'time_assigned', 5, isset($_POST['time_assigned']) ? $_POST['time_assigned'] : $sel_time, $lang->def('_TEST_QUEST_TIMEASS'), $lang->def('_SECONDS')) . Form::getBreakRow() . Form::getTextfield($lang->def('_MAX_SCORE'), 'max_score', 'max_score', 255, isset($_POST['max_score']) ? $_POST['max_score'] : $max_score, $lang->def('_MAX_SCORE')) . Form::getBreakRow() . Form::closeElementSpace() . Form::openButtonSpace() . Form::getButton('add_question', 'add_question', $lang->def('_SAVE')) . Form::closeButtonSpace() . Form::closeForm() . '</div>', 'content');
 }
开发者ID:abhinay100,项目名称:forma_app,代码行数:27,代码来源:class.extended_text.php

示例6: organization_jump_select_sco

function organization_jump_select_sco(&$treeView, $idItem, $folder = false, $data = false, $type = false)
{
    $idResource = $data[REPOFIELDIDRESOURCE];
    $url = 'index.php?modname=storage&op=org_select_sco&idResource=' . $idResource;
    $url .= '&scormorg_title=' . urlencode($data[REPOFIELDTITLE]) . '&amp;idItem=' . $idItem;
    Util::jump_to($url);
    die;
}
开发者ID:abhinay100,项目名称:forma_app,代码行数:8,代码来源:orgcategorize.php

示例7: loginDispatch

function loginDispatch($op)
{
    switch ($op) {
        case "login":
            Util::jump_to(Get::rel_path('base') . '/index.php?modname=login&amp;op=login');
            //login();
            break;
    }
}
开发者ID:abhinay100,项目名称:forma_app,代码行数:9,代码来源:login.php

示例8: saveTask

 public function saveTask()
 {
     $model = new SettingAdm();
     $active_tab = importVar('active_tab', false, 1);
     if ($model->saveElement($active_tab)) {
         Util::jump_to('index.php?r=adm/setting/show&active_tab=' . $active_tab . '&result=ok');
     } else {
         Util::jump_to('index.php?r=adm/setting/show&active_tab=' . $active_tab . '&result=err');
     }
 }
开发者ID:abhinay100,项目名称:forma_app,代码行数:10,代码来源:SettingAdmController.php

示例9: show

 public function show()
 {
     $model = new ClassroomLms();
     if (Get::sett('on_usercourse_empty') === 'on') {
         $conditions_t = array('cu.iduser = :id_user');
         $params_t = array(':id_user' => (int) Docebo::user()->getId());
         $cp_courses = $model->getUserCoursePathCourses(Docebo::user()->getIdst());
         if (!empty($cp_courses)) {
             $conditions_t[] = "cu.idCourse NOT IN (" . implode(",", $cp_courses) . ")";
         }
         $courselist_t = $model->findAll($conditions_t, $params_t);
         if (empty($courselist_t)) {
             Util::jump_to('index.php?r=lms/catalog/show&sop=unregistercourse');
         }
     }
     require_once _lms_ . '/lib/lib.middlearea.php';
     $ma = new Man_MiddleArea();
     $block_list = array();
     if ($ma->currentCanAccessObj('user_details_short')) {
         $block_list['user_details_short'] = true;
     }
     if ($ma->currentCanAccessObj('user_details_full')) {
         $block_list['user_details_full'] = true;
     }
     if ($ma->currentCanAccessObj('credits')) {
         $block_list['credits'] = true;
     }
     if ($ma->currentCanAccessObj('news')) {
         $block_list['news'] = true;
     }
     $tb_label = $ma->currentCanAccessObj('tb_label');
     if (!$tb_label) {
         $_SESSION['id_common_label'] = 0;
     } else {
         $id_common_label = Get::req('id_common_label', DOTY_INT, -1);
         if ($id_common_label >= 0) {
             $_SESSION['id_common_label'] = $id_common_label;
         } elseif ($id_common_label == -2) {
             $_SESSION['id_common_label'] = -1;
         }
         $block_list['labels'] = true;
     }
     if ($tb_label && $_SESSION['id_common_label'] == -1) {
         require_once _lms_ . '/admin/models/LabelAlms.php';
         $label_model = new LabelAlms();
         $user_label = $label_model->getLabelForUser(Docebo::user()->getId());
         $this->render('_labels', array('block_list' => $block_list, 'label' => $user_label));
     } else {
         if (!empty($block_list)) {
             $this->render('_tabs_block', array('block_list' => $block_list));
         } else {
             $this->render('_tabs', array());
         }
     }
 }
开发者ID:abhinay100,项目名称:forma_app,代码行数:55,代码来源:ClassroomLmsController.php

示例10: edit

 function edit($back_poll)
 {
     $lang =& DoceboLanguage::createInstance('poll');
     require_once _base_ . '/lib/lib.form.php';
     $url_encode = htmlentities(urlencode($back_poll));
     if (isset($_POST['add_question'])) {
         if (!sql_query("\r\n\t\t\tUPDATE " . $GLOBALS['prefix_lms'] . "_pollquest \r\n\t\t\tSET title_quest = '" . $_POST['title_quest'] . "' \r\n\t\t\tWHERE id_quest = '" . $this->id . "'")) {
             errorCommunication($lang->def('_ERR_INS_QUEST') . getBackUi('index.php?modname=question_poll&amp;op=edit&amp;type_quest=' . $this->getQuestionType() . '&amp;id_quest=' . $this->id . '&amp;back_poll=' . $url_encode, $lang->def('_BACK')));
         }
         Util::jump_to('' . $back_poll);
     }
     list($title_quest) = sql_fetch_row(sql_query("\r\n\t\tSELECT title_quest \r\n\t\tFROM " . $GLOBALS['prefix_lms'] . "_pollquest \r\n\t\tWHERE id_quest = '" . $this->id . "'"));
     $GLOBALS['page']->add(getTitleArea($lang->def('_POLL_SECTION'), 'poll') . '<div class="std_block">' . getBackUi(Util::str_replace_once('&', '&amp;', $back_poll), $lang->def('_BACK')) . '<div class="title_big">' . $lang->def('_QUEST_ACRN_' . strtoupper($this->getQuestionType())) . ' - ' . $lang->def('_QUEST_' . strtoupper($this->getQuestionType())) . '</div><br />' . Form::openForm('form_mod_quest', 'index.php?modname=question_poll&amp;op=edit') . Form::openElementSpace() . Form::getHidden('type_quest', 'type_quest', $this->getQuestionType()) . Form::getHidden('id_quest', 'id_quest', $this->id) . Form::getHidden('back_poll', 'back_poll', $url_encode) . Form::getTextarea($lang->def('_POLL_QUEST_TITLE'), 'title_quest', 'title_quest', $title_quest) . Form::closeElementSpace() . Form::openButtonSpace() . Form::getButton('add_question', 'add_question', $lang->def('_SAVE')) . Form::closeButtonSpace() . Form::closeForm() . '</div>', 'content');
 }
开发者ID:abhinay100,项目名称:forma_app,代码行数:14,代码来源:class.title.php

示例11: env_play

function env_play($lobj, $options)
{
    list($file) = sql_fetch_row(sql_query("SELECT path" . " FROM %lms_materials_lesson" . " WHERE idLesson = " . (int) $lobj->id . ""));
    if (!$file) {
        Util::jump_to($lobj->back_url);
    }
    $id_param = $lobj->getIdParam();
    if ($lobj->id_reference != false) {
        require_once _lms_ . '/class.module/track.item.php';
        $ti = new Track_Item($lobj, Docebo::user()->getIdSt());
        // need id_resource, id_reference, type and environment
        $ti->setDate(date('Y-m-d H:i:s'));
        $ti->status = 'completed';
        $ti->update();
    }
    Util::download('/appLms/' . Get::sett('pathlesson'), $file);
}
开发者ID:abhinay100,项目名称:forma_app,代码行数:17,代码来源:do.item.php

示例12: set

 /**
  * Set the new fields and policy acceptance, than jump to the proper page
  */
 public function set()
 {
     $id_user = Docebo::user()->getIdst();
     require_once _adm_ . '/lib/lib.field.php';
     $fl = new FieldList();
     $fl->storeFieldsForUser($id_user);
     $accept_policy = Get::req('accept_policy', DOTY_INT, 0) > 0;
     $this->model->setAcceptingPolicy($id_user, $accept_policy);
     $policy_checked = $this->model->getAcceptingPolicy($id_user);
     $fields_checked = $fl->checkUserMandatoryFields($id_user);
     if ($fields_checked && $policy_checked) {
         //send alert
         Util::jump_to($this->jump_url);
     } else {
         //send alert
         Util::jump_to('index.php?r=precompile/show&res=err');
     }
 }
开发者ID:abhinay100,项目名称:forma_app,代码行数:21,代码来源:PrecompileLmsController.php

示例13: edit

 public function edit()
 {
     //Course info
     $id_course = Get::req('id_course', DOTY_INT, 0);
     $id_edition = Get::req('id_edition', DOTY_INT, 0);
     $model = new EditionLms($id_course, $id_edition);
     $edition_info = $model->getEditionInfo($id_edition);
     if (isset($_POST['undo'])) {
         Util::jump_to('index.php?r=edition/show&id_course=' . $model->getIdCourse());
     } elseif (isset($_POST['mod'])) {
         if ($model->modEdition()) {
             Util::jump_to('index.php?r=edition/show&id_course=' . $model->getIdCourse() . '&result=ok');
         }
         Util::jump_to('index.php?r=edition/show&id_course=' . $model->getIdCourse() . '&result=err_mod');
     } else {
         $this->render('edit', array('model' => $model, 'edition_info' => $edition_info));
     }
 }
开发者ID:abhinay100,项目名称:forma_app,代码行数:18,代码来源:EditionLmsController.php

示例14: renewalpwd

function renewalpwd()
{
    require_once _base_ . '/lib/lib.usermanager.php';
    $user_manager = new UserManager();
    $lang =& DoceboLanguage::createInstance('profile', 'framework');
    if ($user_manager->clickSaveElapsed()) {
        $error = $user_manager->saveElapsedPassword();
        if ($error['error'] != true) {
            unset($_SESSION['must_renew_pwd']);
            Util::jump_to('index.php?r=elearning/show&sop=unregistercourse');
        }
    }
    $_SESSION['must_renew_pwd'] = 1;
    $res = Docebo::user()->isPasswordElapsed();
    if ($res == 2) {
        $GLOBALS['page']->add(getTitleArea($lang->def('_CHANGEPASSWORD')), 'content');
    } else {
        $GLOBALS['page']->add(getTitleArea($lang->def('_TITLE_CHANGE')), 'content');
    }
    $GLOBALS['page']->add('<div class="std_block">' . $user_manager->getElapsedPassword('index.php?modname=profile&amp;op=renewalpwd') . '</div>', 'content');
}
开发者ID:abhinay100,项目名称:forma_app,代码行数:21,代码来源:profile.php

示例15: transactionDispatch

function transactionDispatch($op)
{
    checkPerm('view');
    require_once _lms_ . '/lib/lib.transaction.php';
    if (isset($_POST['back_mod'])) {
        Util::jump_to('index.php?modname=transaction&amp;op=transaction');
    }
    switch ($op) {
        case 'mod':
            modTransaction();
            break;
        case 'del':
            delTransaction();
            break;
        default:
        case 'transaction':
            transaction();
            break;
    }
}
开发者ID:abhinay100,项目名称:forma_app,代码行数:20,代码来源:transaction.php


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