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


PHP moodle_url::out_omit_querystring方法代码示例

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


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

示例1: destination_courses_selector

 public function destination_courses_selector(moodle_url $nextstageurl, destination_courses_search $courses = null, $courseid)
 {
     $html = html_writer::start_tag('div', array('class' => 'import-course-selector backup-restore'));
     $html .= html_writer::start_tag('form', array('method' => 'post', 'action' => $nextstageurl->out_omit_querystring()));
     foreach ($nextstageurl->params() as $key => $value) {
         $html .= html_writer::empty_tag('input', array('type' => 'hidden', 'name' => $key, 'value' => $value));
     }
     $html .= html_writer::start_tag('div', array('class' => 'ics-existing-group backup-section'));
     $html .= $this->output->heading(get_string('selectgroups', 'local_syncgroups'), 2, array('class' => 'header'));
     $html .= html_writer::start_tag('ul');
     $groups = groups_get_all_groups($courseid, 0, 0, 'g.id, g.name');
     foreach ($groups as $group) {
         $html .= html_writer::start_tag('li') . html_writer::checkbox('groups[]', $group->id, false, $group->name) . html_writer::end_tag('li');
     }
     $html .= html_writer::end_tag('ul');
     $html .= html_writer::end_tag('div');
     // We only allow import adding for now. Enforce it here.
     $html .= html_writer::start_tag('div', array('class' => 'ics-existing-course backup-section'));
     $html .= $this->output->heading(get_string('syncgroupsto', 'local_syncgroups'), 2, array('class' => 'header'));
     $html .= $this->backup_detail_pair(get_string('selectacourse', 'backup'), $this->render($courses));
     $html .= $this->backup_detail_pair('', html_writer::empty_tag('input', array('type' => 'submit', 'value' => get_string('continue'))));
     $html .= html_writer::end_tag('div');
     $html .= html_writer::end_tag('form');
     $html .= html_writer::end_tag('div');
     return $html;
 }
开发者ID:danielneis,项目名称:moodle-local_syncgroups,代码行数:26,代码来源:renderer.php

示例2: wrap_html_start

 public function wrap_html_start()
 {
     global $PAGE;
     if ($this->is_downloading() || !$this->candelete) {
         return;
     }
     // Start form
     $url = new moodle_url($this->reporturl, $this->displayoptions);
     $url->param('sesskey', sesskey());
     echo '<div id="tablecontainer">';
     echo '<form id="attemptsform" method="post" action="' . $url->out_omit_querystring() . '>';
     echo html_writer::input_hidden_params($url);
     echo '<div>';
     $PAGE->requires->event_handler('#attemptsform', 'submit', 'M.util.show_confirm_dialog', array('message' => get_string('deleteattemptcheck', 'quiz')));
 }
开发者ID:sebastiansanio,项目名称:tallerdeprogramacion2fiuba,代码行数:15,代码来源:responses_table.php

示例3: array

 function wrap_html_start()
 {
     if (!$this->is_downloading()) {
         if ($this->candelete) {
             // Start form
             $url = new moodle_url($this->reporturl, $this->displayoptions);
             echo '<div id="tablecontainer">';
             echo '<form id="attemptsform" method="post" action="' . $url->out_omit_querystring() . '">';
             echo '<div style="display: none;">';
             echo html_writer::input_hidden_params($url);
             echo html_writer::empty_tag('input', array('type' => 'hidden', 'name' => 'sesskey', 'value' => sesskey())) . "\n";
             echo '</div>';
             echo '<div>';
         }
     }
 }
开发者ID:esyacelga,项目名称:sisadmaca,代码行数:16,代码来源:overview_table.php

示例4: array

 function wrap_html_start()
 {
     if (!$this->is_downloading()) {
         if ($this->candelete) {
             // Start form
             $displayurl = new moodle_url($this->reporturl, $this->displayoptions);
             $strreallydel = addslashes_js(get_string('deleteattemptcheck', 'quiz'));
             echo '<div id="tablecontainer">';
             echo '<form id="attemptsform" method="post" action="' . $displayurl->out_omit_querystring() . '" onsubmit="confirm(\'' . $strreallydel . '\');">';
             echo '<div style="display: none;">';
             echo html_writer::input_hidden_params($displayurl);
             echo html_writer::empty_tag('input', array('type' => 'hidden', 'name' => 'sesskey', 'value' => sesskey())) . "\n";
             echo '</div>';
             echo '<div>';
         }
     }
 }
开发者ID:vuchannguyen,项目名称:web,代码行数:17,代码来源:responses_table.php

示例5: display

 /**
  * Renders the process stage screen
  *
  * @throws restore_ui_exception
  * @param core_backup_renderer $renderer renderer instance to use
  * @return string HTML code
  */
 public function display(core_backup_renderer $renderer)
 {
     global $PAGE;
     $html = '';
     $haserrors = false;
     $url = new moodle_url($PAGE->url, array('restore' => $this->get_uniqueid(), 'stage' => restore_ui::STAGE_PROCESS, 'substage' => $this->substage, 'sesskey' => sesskey()));
     $html .= html_writer::start_tag('form', array('action' => $url->out_omit_querystring(), 'class' => 'backup-restore', 'enctype' => 'application/x-www-form-urlencoded', 'method' => 'post'));
     foreach ($url->params() as $name => $value) {
         $html .= html_writer::empty_tag('input', array('type' => 'hidden', 'name' => $name, 'value' => $value));
     }
     switch ($this->substage) {
         case self::SUBSTAGE_PRECHECKS:
             $results = $this->ui->get_controller()->get_precheck_results();
             $info = $this->ui->get_controller()->get_info();
             $haserrors = !empty($results['errors']);
             $html .= $renderer->precheck_notices($results);
             if (!empty($info->role_mappings->mappings)) {
                 $context = context_course::instance($this->ui->get_controller()->get_courseid());
                 $assignableroles = get_assignable_roles($context, ROLENAME_ALIAS, false);
                 $html .= $renderer->role_mappings($info->role_mappings->mappings, $assignableroles);
             }
             break;
         default:
             throw new restore_ui_exception('backup_ui_must_execute_first');
     }
     $html .= $renderer->substage_buttons($haserrors);
     $html .= html_writer::end_tag('form');
     return $html;
 }
开发者ID:educakanchay,项目名称:campus,代码行数:36,代码来源:restore_ui_stage.class.php

示例6: import_course_selector

 /**
  * Displays the import course selector
  *
  * @param moodle_url $nextstageurl
  * @param import_course_search $courses
  * @return string
  */
 public function import_course_selector(moodle_url $nextstageurl, import_course_search $courses = null)
 {
     $html = html_writer::start_tag('div', array('class' => 'import-course-selector backup-restore'));
     $html .= html_writer::start_tag('form', array('method' => 'post', 'action' => $nextstageurl->out_omit_querystring()));
     foreach ($nextstageurl->params() as $key => $value) {
         $html .= html_writer::empty_tag('input', array('type' => 'hidden', 'name' => $key, 'value' => $value));
     }
     // We only allow import adding for now. Enforce it here.
     $html .= html_writer::empty_tag('input', array('type' => 'hidden', 'name' => 'target', 'value' => backup::TARGET_CURRENT_ADDING));
     $html .= html_writer::start_tag('div', array('class' => 'ics-existing-course backup-section'));
     $html .= $this->output->heading(get_string('importdatafrom'), 2, array('class' => 'header'));
     $html .= $this->backup_detail_pair(get_string('selectacourse', 'backup'), $this->render($courses));
     $html .= $this->backup_detail_pair('', html_writer::empty_tag('input', array('type' => 'submit', 'value' => get_string('continue'))));
     $html .= html_writer::end_tag('div');
     $html .= html_writer::end_tag('form');
     $html .= html_writer::end_tag('div');
     return $html;
 }
开发者ID:janaece,项目名称:globalclassroom4_clean,代码行数:25,代码来源:renderer.php

示例7: get_preflight_check_form

 /**
  * Build the form required to do the pre-flight checks.
  * @param moodle_url $url the form action URL.
  * @param int|null $attemptid the id of the current attempt, if there is one,
  *      otherwise null.
  * @return mod_quiz_preflight_check_form the form.
  */
 public function get_preflight_check_form(moodle_url $url, $attemptid) {
     return new mod_quiz_preflight_check_form($url->out_omit_querystring(),
             array('rules' => $this->rules, 'quizobj' => $this->quizobj,
                   'attemptid' => $attemptid, 'hidden' => $url->params()));
 }
开发者ID:JP-Git,项目名称:moodle,代码行数:12,代码来源:accessmanager.php

示例8: get_preflight_check_form

 /**
  * Build the form required to do the pre-flight checks.
  * @param moodle_url $url the form action URL.
  * @param int|null $attemptid the id of the current attempt, if there is one,
  *      otherwise null.
  * @return mod_quiz_preflight_check_form the form.
  */
 public function get_preflight_check_form(moodle_url $url, $attemptid)
 {
     // This form normally wants POST submissins. However, it also needs to
     // accept GET submissions. Since formslib is strict, we have to detect
     // which case we are in, and set the form property appropriately.
     $method = 'post';
     if (!empty($_GET['_qf__mod_quiz_preflight_check_form'])) {
         $method = 'get';
     }
     return new mod_quiz_preflight_check_form($url->out_omit_querystring(), array('rules' => $this->rules, 'quizobj' => $this->quizobj, 'attemptid' => $attemptid, 'hidden' => $url->params()), $method);
 }
开发者ID:gabrielrosset,项目名称:moodle,代码行数:18,代码来源:accessmanager.php

示例9: display

 /**
  * should NEVER be called... throws an exception
  */
 public function display($renderer)
 {
     global $PAGE;
     $haserrors = false;
     $url = new moodle_url($PAGE->url, array('restore' => $this->get_uniqueid(), 'stage' => restore_ui::STAGE_PROCESS, 'substage' => $this->substage, 'sesskey' => sesskey()));
     echo html_writer::start_tag('form', array('action' => $url->out_omit_querystring(), 'class' => 'backup-restore', 'method' => 'post'));
     foreach ($url->params() as $name => $value) {
         echo html_writer::empty_tag('input', array('type' => 'hidden', 'name' => $name, 'value' => $value));
     }
     switch ($this->substage) {
         case self::SUBSTAGE_CONVERT:
             echo '<h2>Need to show the conversion screens here</h2>';
             break;
         case self::SUBSTAGE_PRECHECKS:
             $results = $this->ui->get_controller()->get_precheck_results();
             $info = $this->ui->get_controller()->get_info();
             $haserrors = !empty($results['errors']);
             echo $renderer->precheck_notices($results);
             if (!empty($info->role_mappings->mappings)) {
                 $context = get_context_instance(CONTEXT_COURSE, $this->ui->get_controller()->get_courseid());
                 $assignableroles = get_assignable_roles($context, ROLENAME_ALIAS, false);
                 echo $renderer->role_mappings($info->role_mappings->mappings, $assignableroles);
             }
             break;
         default:
             throw new restore_ui_exception('backup_ui_must_execute_first');
     }
     echo $renderer->substage_buttons($haserrors);
     echo html_writer::end_tag('form');
 }
开发者ID:vuchannguyen,项目名称:web,代码行数:33,代码来源:restore_ui_stage.class.php

示例10: display

 public function display($quiz, $cm, $course)
 {
     global $CFG, $DB, $OUTPUT, $PAGE;
     list($currentgroup, $students, $groupstudents, $allowed) = $this->init('overview', 'quiz_overview_settings_form', $quiz, $cm, $course);
     $options = new quiz_overview_options('overview', $quiz, $cm, $course);
     if ($fromform = $this->form->get_data()) {
         $options->process_settings_from_form($fromform);
     } else {
         $options->process_settings_from_params();
     }
     $this->form->set_data($options->get_initial_form_data());
     if ($options->attempts == self::ALL_WITH) {
         // This option is only available to users who can access all groups in
         // groups mode, so setting allowed to empty (which means all quiz attempts
         // are accessible, is not a security porblem.
         $allowed = array();
     }
     // Load the required questions.
     $questions = quiz_report_get_significant_questions($quiz);
     // Prepare for downloading, if applicable.
     $courseshortname = format_string($course->shortname, true, array('context' => context_course::instance($course->id)));
     $table = new quiz_overview_table($quiz, $this->context, $this->qmsubselect, $options, $groupstudents, $students, $questions, $options->get_url());
     $filename = quiz_report_download_filename(get_string('overviewfilename', 'quiz_overview'), $courseshortname, $quiz->name);
     $table->is_downloading($options->download, $filename, $courseshortname . ' ' . format_string($quiz->name, true));
     if ($table->is_downloading()) {
         raise_memory_limit(MEMORY_EXTRA);
     }
     $this->course = $course;
     // Hack to make this available in process_actions.
     $this->process_actions($quiz, $cm, $currentgroup, $groupstudents, $allowed, $options->get_url());
     // Start output.
     if (!$table->is_downloading()) {
         // Only print headers if not asked to download data.
         $this->print_header_and_tabs($cm, $course, $quiz, $this->mode);
     }
     if ($groupmode = groups_get_activity_groupmode($cm)) {
         // Groups are being used, so output the group selector if we are not downloading.
         if (!$table->is_downloading()) {
             groups_print_activity_menu($cm, $options->get_url());
         }
     }
     // Print information on the number of existing attempts.
     if (!$table->is_downloading()) {
         // Do not print notices when downloading.
         if ($strattemptnum = quiz_num_attempt_summary($quiz, $cm, true, $currentgroup)) {
             echo '<div class="quizattemptcounts">' . $strattemptnum . '</div>';
         }
     }
     $hasquestions = quiz_questions_in_quiz($quiz->questions);
     if (!$table->is_downloading()) {
         if (!$hasquestions) {
             echo quiz_no_questions_message($quiz, $cm, $this->context);
         } else {
             if (!$students) {
                 echo $OUTPUT->notification(get_string('nostudentsyet'));
             } else {
                 if ($currentgroup && !$groupstudents) {
                     echo $OUTPUT->notification(get_string('nostudentsingroup'));
                 }
             }
         }
         // Print the display options.
         $this->form->display();
     }
     $hasstudents = $students && (!$currentgroup || $groupstudents);
     if ($hasquestions && ($hasstudents || $options->attempts == self::ALL_WITH)) {
         // Construct the SQL.
         $fields = $DB->sql_concat('u.id', "'#'", 'COALESCE(quiza.attempt, 0)') . ' AS uniqueid, ';
         if ($this->qmsubselect) {
             $fields .= "(CASE " . "   WHEN {$this->qmsubselect} THEN 1" . "   ELSE 0 " . "END) AS gradedattempt, ";
         }
         list($fields, $from, $where, $params) = $table->base_sql($allowed);
         $table->set_count_sql("SELECT COUNT(1) FROM {$from} WHERE {$where}", $params);
         // Test to see if there are any regraded attempts to be listed.
         $fields .= ", COALESCE((\n                                SELECT MAX(qqr.regraded)\n                                  FROM {quiz_overview_regrades} qqr\n                                 WHERE qqr.questionusageid = quiza.uniqueid\n                          ), -1) AS regraded";
         if ($options->onlyregraded) {
             $where .= " AND COALESCE((\n                                    SELECT MAX(qqr.regraded)\n                                      FROM {quiz_overview_regrades} qqr\n                                     WHERE qqr.questionusageid = quiza.uniqueid\n                                ), -1) <> -1";
         }
         $table->set_sql($fields, $from, $where, $params);
         if (!$table->is_downloading()) {
             // Output the regrade buttons.
             if (has_capability('mod/quiz:regrade', $this->context)) {
                 $regradesneeded = $this->count_question_attempts_needing_regrade($quiz, $groupstudents);
                 if ($currentgroup) {
                     $a = new stdClass();
                     $a->groupname = groups_get_group_name($currentgroup);
                     $a->coursestudents = get_string('participants');
                     $a->countregradeneeded = $regradesneeded;
                     $regradealldrydolabel = get_string('regradealldrydogroup', 'quiz_overview', $a);
                     $regradealldrylabel = get_string('regradealldrygroup', 'quiz_overview', $a);
                     $regradealllabel = get_string('regradeallgroup', 'quiz_overview', $a);
                 } else {
                     $regradealldrydolabel = get_string('regradealldrydo', 'quiz_overview', $regradesneeded);
                     $regradealldrylabel = get_string('regradealldry', 'quiz_overview');
                     $regradealllabel = get_string('regradeall', 'quiz_overview');
                 }
                 $displayurl = new moodle_url($options->get_url(), array('sesskey' => sesskey()));
                 echo '<div class="mdl-align">';
                 echo '<form action="' . $displayurl->out_omit_querystring() . '">';
                 echo '<div>';
//.........这里部分代码省略.........
开发者ID:tyleung,项目名称:CMPUT401MoodleExams,代码行数:101,代码来源:report.php

示例11: display


//.........这里部分代码省略.........
            if (quiz_get_regraded_qs($sqlobject, 0, 1)) {
                $regradedattempts = true;
            } else {
                $regradedattempts = false;
            }
            $fields .= ', COALESCE((SELECT MAX(qqr.regraded) FROM {quiz_question_regrade} qqr WHERE qqr.attemptid = qa.uniqueid),-1) AS regraded';
            if ($regradefilter) {
                $where .= ' AND COALESCE((SELECT MAX(qqr.regraded) FROM {quiz_question_regrade} qqr WHERE qqr.attemptid = qa.uniqueid),-1) !=\'-1\'';
            }
            $table->set_sql($fields, $from, $where, $params);

            // Define table columns
            $columns = array();
            $headers = array();
            if (!$table->is_downloading()) { //do not print notices when downloading
                //regrade buttons
                if (has_capability('mod/quiz:regrade', $this->context)) {
                    $countregradeneeded = $this->count_regrade_all_needed($quiz, $groupstudents);
                    if ($currentgroup) {
                        $a= new stdClass();
                        $a->groupname = groups_get_group_name($currentgroup);
                        $a->coursestudents = get_string('participants');
                        $a->countregradeneeded = $countregradeneeded;
                        $regradealldrydolabel = get_string('regradealldrydogroup', 'quiz_overview', $a);
                        $regradealldrylabel = get_string('regradealldrygroup', 'quiz_overview', $a);
                        $regradealllabel = get_string('regradeallgroup', 'quiz_overview', $a);
                    } else {
                        $regradealldrydolabel = get_string('regradealldrydo', 'quiz_overview', $countregradeneeded);
                        $regradealldrylabel = get_string('regradealldry', 'quiz_overview');
                        $regradealllabel = get_string('regradeall', 'quiz_overview');
                    }
                    $displayurl = new moodle_url($reporturl, $displayoptions);
                    echo '<div class="mdl-align">';
                    echo '<form action="'.$displayurl->out_omit_querystring().'">';
                    echo '<div>';
                    echo html_writer::input_hidden_params($displayurl);
                    echo html_writer::empty_tag('input', array('type' => 'hidden', 'name' => 'sesskey', 'value' => sesskey())) . "\n";
                    echo '<input type="submit" name="regradeall" value="'.$regradealllabel.'"/>';
                    echo '<input type="submit" name="regradealldry" value="'.$regradealldrylabel.'"/>';
                    if ($countregradeneeded) {
                        echo '<input type="submit" name="regradealldrydo" value="'.$regradealldrydolabel.'"/>';
                    }
                    echo '</div>';
                    echo '</form>';
                    echo '</div>';
                }
                // Print information on the grading method
                if ($strattempthighlight = quiz_report_highlighting_grading_method($quiz, $qmsubselect, $qmfilter)) {
                    echo '<div class="quizattemptcounts">' . $strattempthighlight . '</div>';
                }
            }

            if (!$table->is_downloading() && $candelete) {
                $columns[]= 'checkbox';
                $headers[]= NULL;
            }

            if (!$table->is_downloading() && $CFG->grade_report_showuserimage) {
                $columns[]= 'picture';
                $headers[]= '';
            }
            if (!$table->is_downloading()) {
                $columns[]= 'fullname';
                $headers[]= get_string('name');
             } else {
                $columns[]= 'lastname';
开发者ID:nuckey,项目名称:moodle,代码行数:67,代码来源:report.php

示例12: everything_download_options

 /**
  * Return a little form for the user to request to download the full report, including quiz stats and response analysis for
  * all questions and sub-questions.
  *
  * @param moodle_url $reporturl the base URL of the report.
  * @return string HTML.
  */
 protected function everything_download_options(moodle_url $reporturl)
 {
     global $OUTPUT;
     return $OUTPUT->download_dataformat_selector(get_string('downloadeverything', 'quiz_statistics'), $reporturl->out_omit_querystring(), 'download', $reporturl->params() + array('everything' => 1));
 }
开发者ID:sirromas,项目名称:lms,代码行数:12,代码来源:report.php

示例13: wrap_html_start

    public function wrap_html_start() {
        if ($this->is_downloading() || !$this->includecheckboxes) {
            return;
        }

        $url = new moodle_url($this->reporturl, $this->displayoptions);
        $url->param('sesskey', sesskey());

        echo '<div id="tablecontainer">';
        echo '<form id="attemptsform" method="post" action="' . $url->out_omit_querystring() . '">';

        echo html_writer::input_hidden_params($url);
        echo '<div>';
    }
开发者ID:nigeli,项目名称:moodle,代码行数:14,代码来源:attemptsreport_table.php

示例14: view_selfregistration


//.........这里部分代码省略.........
                     $attr['group'] = $agrpid;
                     // Try only!
                     list($error, $confirmmessage) = $this->unregister_from_agrp($agrpid, $USER->id, true);
                 } else {
                     require_capability('mod/grouptool:register', $this->context);
                     $action = 'reg';
                     $attr['group'] = $agrpid;
                     // Try only!
                     list($error, $confirmmessage) = $this->register_in_agrp($agrpid, $USER->id, true);
                 }
             }
             $attr['confirm'] = '1';
             $attr['action'] = $action;
             $attr['sesskey'] = sesskey();
             $continue = new moodle_url($PAGE->url, $attr);
             $cancel = new moodle_url($PAGE->url);
             if ($error === true && $action != 'resolvequeues') {
                 $continue->remove_params('confirm', 'group');
                 $continue = new single_button($continue, get_string('continue'), 'get');
                 $cancel = null;
             }
             echo $this->confirm($confirmmessage, $continue, $cancel);
         } else {
             $hideform = 0;
         }
     }
     if (empty($hideform)) {
         /*
          * we need a new moodle_url-Object because
          * $PAGE->url->param('sesskey', sesskey());
          * won't set sesskey param in $PAGE->url?!?
          */
         $url = new moodle_url($PAGE->url, array('sesskey' => sesskey()));
         $formattr = array('method' => 'post', 'action' => $url->out_omit_querystring(), 'id' => 'registration_form', 'class' => 'mform');
         echo html_writer::start_tag('form', $formattr);
         echo html_writer::start_tag('div', array('class' => 'clearfix'));
         echo html_writer::input_hidden_params($url);
         $regstat = $this->get_registration_stats($USER->id);
         if (!empty($this->grouptool->timedue) && time() >= $this->grouptool->timedue && has_capability('mod/grouptool:register_students', $this->context)) {
             if ($regstat->queued_users > 0) {
                 // Insert queue-resolving button!
                 $attr = array('type' => 'submit', 'name' => 'resolve_queues', 'value' => '1');
                 $resolvequeuebutton = html_writer::tag('button', get_string('resolve_queue', 'grouptool'), $attr);
                 $resolvequeue = html_writer::tag('div', get_string('resolve_queue_title', 'grouptool'), array('class' => 'fitemtitle')) . html_writer::tag('div', $resolvequeuebutton, array('class' => 'felement'));
                 $resolvequeue = html_writer::tag('div', $resolvequeue, array('class' => 'fitem'));
                 $resolvequeuelegend = html_writer::tag('legend', get_string('resolve_queue_legend', 'grouptool'));
                 $resolvequeueelement = html_writer::tag('div', $resolvequeue, array('class' => 'fcontainer'));
                 echo html_writer::tag('fieldset', $resolvequeuelegend . $resolvequeueelement, array('class' => 'clearfix'));
             }
         }
         if (!empty($this->grouptool->use_size)) {
             $placestats = $regstat->group_places . '&nbsp;' . get_string('total', 'grouptool');
         } else {
             $placestats = '∞&nbsp;' . get_string('total', 'grouptool');
         }
         if ($regstat->free_places != null && !empty($this->grouptool->use_size)) {
             $placestats .= ' / ' . $regstat->free_places . '&nbsp;' . get_string('free', 'grouptool');
         } else {
             $placestats .= ' / ∞&nbsp;' . get_string('free', 'grouptool');
         }
         if ($regstat->occupied_places != null) {
             $placestats .= ' / ' . $regstat->occupied_places . '&nbsp;' . get_string('occupied', 'grouptool');
         }
         $registrationinfo = html_writer::tag('div', get_string('group_places', 'grouptool') . $OUTPUT->help_icon('group_places', 'grouptool'), array('class' => 'fitemtitle')) . html_writer::tag('div', $placestats, array('class' => 'felement'));
         $generalinfo = html_writer::tag('div', $registrationinfo, array('class' => 'fitem'));
         $registrationinfo = html_writer::tag('div', get_string('number_of_students', 'grouptool'), array('class' => 'fitemtitle')) . html_writer::tag('div', $regstat->users, array('class' => 'felement'));
开发者ID:rimacher,项目名称:moodle-mod_grouptool,代码行数:67,代码来源:locallib.php

示例15: array


//.........这里部分代码省略.........
                 $optional = ' class="itemoptional ' . $itemcolour . $autoclass . '" ';
             } else {
                 if ($item->itemoptional == CHECKLIST_OPTIONAL_HEADING) {
                     if ($item->hidden) {
                         $title = '"' . get_string('headingitem', 'checklist') . '"';
                         echo '<img src="' . $OUTPUT->pix_url('no_box', 'checklist') . '" alt=' . $title . ' title=' . $title . ' />&nbsp;';
                         $optional = ' class="' . $itemcolour . $autoclass . ' itemdisabled"';
                     } else {
                         $title = '"' . get_string('headingitem', 'checklist') . '"';
                         if (!$autoitem) {
                             echo '<a href="' . $thispage->out(true, array('action' => 'makerequired')) . '">';
                         }
                         echo '<img src="' . $OUTPUT->pix_url('no_box', 'checklist') . '" alt=' . $title . ' title=' . $title . ' />';
                         if (!$autoitem) {
                             echo '</a>';
                         }
                         echo '&nbsp;';
                         $optional = ' class="itemheading ' . $itemcolour . $autoclass . '" ';
                     }
                 } else {
                     if ($item->hidden) {
                         $title = '"' . get_string('requireditem', 'checklist') . '"';
                         echo '<img src="' . $OUTPUT->pix_url('tick_box', 'checklist') . '" alt=' . $title . ' title=' . $title . ' />&nbsp;';
                         $optional = ' class="' . $itemcolour . $autoclass . ' itemdisabled"';
                     } else {
                         $title = '"' . get_string('requireditem', 'checklist') . '"';
                         echo '<a href="' . $thispage->out(true, array('action' => 'makeoptional')) . '">';
                         echo '<img src="' . $OUTPUT->pix_url('tick_box', 'checklist') . '" alt=' . $title . ' title=' . $title . ' /></a>&nbsp;';
                         $optional = ' class="' . $itemcolour . $autoclass . '"';
                     }
                 }
             }
             if (isset($item->editme)) {
                 echo '<form style="display:inline" action="' . $thispage->out_omit_querystring() . '" method="post">';
                 echo '<input type="text" size="' . CHECKLIST_TEXT_INPUT_WIDTH . '" name="displaytext" value="' . s($item->displaytext) . '" id="updateitembox" />';
                 echo '<input type="hidden" name="action" value="updateitem" />';
                 echo html_writer::input_hidden_params($thispage);
                 if ($this->editdates) {
                     $this->print_edit_date($item->duetime);
                 }
                 echo '<input type="submit" name="updateitem" value="' . get_string('updateitem', 'checklist') . '" />';
                 echo '</form>';
                 $focusitem = 'updateitembox';
                 echo '<form style="display:inline" action="' . $thispage->out_omit_querystring() . '" method="get">';
                 echo html_writer::input_hidden_params($thispage, array('sesskey', 'itemid'));
                 echo '<input type="submit" name="canceledititem" value="' . get_string('canceledititem', 'checklist') . '" />';
                 echo '</form>';
                 $addatend = false;
             } else {
                 echo '<label for=' . $itemname . $optional . '>' . s($item->displaytext) . '</label>&nbsp;';
                 echo '<a href="' . $thispage->out(true, array('action' => 'nextcolour')) . '">';
                 $title = '"' . get_string('changetextcolour', 'checklist') . '"';
                 echo '<img src="' . $OUTPUT->pix_url($nexticon, 'checklist') . '" alt=' . $title . ' title=' . $title . ' /></a>';
                 if (!$autoitem) {
                     echo '<a href="' . $thispage->out(true, array('action' => 'edititem')) . '">';
                     $title = '"' . get_string('edititem', 'checklist') . '"';
                     echo '<img src="' . $OUTPUT->pix_url('/t/edit') . '"  alt=' . $title . ' title=' . $title . ' /></a>&nbsp;';
                 }
                 if (!$autoitem && $item->indent > 0) {
                     echo '<a href="' . $thispage->out(true, array('action' => 'unindentitem')) . '">';
                     $title = '"' . get_string('unindentitem', 'checklist') . '"';
                     echo '<img src="' . $OUTPUT->pix_url('/t/left') . '" alt=' . $title . ' title=' . $title . '  /></a>';
                 }
                 if (!$autoitem && $item->indent < CHECKLIST_MAX_INDENT && $lastindent + 1 > $currindent) {
                     echo '<a href="' . $thispage->out(true, array('action' => 'indentitem')) . '">';
                     $title = '"' . get_string('indentitem', 'checklist') . '"';
开发者ID:rlorenzo,项目名称:moodle-checklist,代码行数:67,代码来源:locallib.php


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