本文整理汇总了PHP中quiz_question_edit_button函数的典型用法代码示例。如果您正苦于以下问题:PHP quiz_question_edit_button函数的具体用法?PHP quiz_question_edit_button怎么用?PHP quiz_question_edit_button使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了quiz_question_edit_button函数的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: quiz_print_singlequestion
/**
* Print a given single question in quiz for the edit tab of edit.php.
* Meant to be used from quiz_print_question_list()
*
* @param object $question A question object from the database questions table
* @param object $returnurl The url to get back to this page, for example after editing.
* @param object $quiz The quiz in the context of which the question is being displayed
*/
function quiz_print_singlequestion($question, $returnurl, $quiz) {
echo '<div class="singlequestion ' . $question->qtype . '">';
echo quiz_question_edit_button($quiz->cmid, $question, $returnurl,
quiz_question_tostring($question) . ' ');
echo '<span class="questiontype">';
echo print_question_icon($question);
echo ' ' . question_bank::get_qtype_name($question->qtype) . '</span>';
echo '<span class="questionpreview">' .
quiz_question_preview_button($quiz, $question, true) . '</span>';
echo "</div>\n";
}
示例2: quiz_question_action_icons
/**
* @param object $quiz the quiz.
* @param int $cmid the course_module object for this quiz.
* @param object $question the question.
* @param string $returnurl url to return to after action is done.
* @return string html for a number of icons linked to action pages for a
* question - preview and edit / view icons depending on user capabilities.
*/
function quiz_question_action_icons($quiz, $cmid, $question, $returnurl) {
$html = quiz_question_preview_button($quiz, $question) . ' ' .
quiz_question_edit_button($cmid, $question, $returnurl);
return $html;
}
示例3: quiz_print_singlequestion
/**
* Print a given single question in quiz for the edit tab of edit.php.
* Meant to be used from quiz_print_question_list()
*
* @param object $question A question object from the database questions table
* @param object $returnurl The url to get back to this page, for example after editing.
* @param object $quiz The quiz in the context of which the question is being displayed
*/
function quiz_print_singlequestion($question, $returnurl, $quiz)
{
global $QTYPES;
echo '<div class="singlequestion">';
echo quiz_question_edit_button($quiz->cmid, $question, $returnurl, quiz_question_tostring($question) . ' ');
echo '<span class="questiontype">';
$namestr = $QTYPES[$question->qtype]->local_name();
print_question_icon($question);
echo " {$namestr}</span>";
echo '<span class="questionpreview">' . quiz_question_preview_button($quiz, $question, true) . '</span>';
echo "</div>\n";
}
示例4: quiz_question_action_icons
/**
* @param object $quiz the quiz.
* @param int $cmid the course_module object for this quiz.
* @param object $question the question.
* @param string $returnurl url to return to after action is done.
* @param int $variant which question variant to preview (optional).
* @return string html for a number of icons linked to action pages for a
* question - preview and edit / view icons depending on user capabilities.
*/
function quiz_question_action_icons($quiz, $cmid, $question, $returnurl, $variant = null)
{
$html = quiz_question_preview_button($quiz, $question, false, $variant) . ' ' . quiz_question_edit_button($cmid, $question, $returnurl);
return $html;
}