本文整理汇总了PHP中quiz::createQuiz方法的典型用法代码示例。如果您正苦于以下问题:PHP quiz::createQuiz方法的具体用法?PHP quiz::createQuiz怎么用?PHP quiz::createQuiz使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类quiz
的用法示例。
在下文中一共展示了quiz::createQuiz方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: quiz
<?php
//$handle=new mysqli('localhost','root','','sygma');
require "class.quiz.php";
$q = new quiz();
$q->createQuiz($_POST);
header('create_question.php');
示例2: classes
*/
if ($_SESSION['username'] != "") {
require_once 'web/core/navigation.php';
if ($_SESSION['utype'] >= '5') {
// get and initiate the course class to access the functions
require_once 'src/core/controller/classes.php';
$ObjClass = new classes();
require_once 'src/core/controller/quiz.php';
$ObjQuiz = new quiz();
// set class id for form and links
if ($_POST['classid'] != "") {
$classid = $_POST['classid'];
} else {
$classid = $d;
}
if ($_POST['y'] == 'quiz' && $_POST['z'] == 'create' && $_POST['action'] == "save") {
$createContent = $ObjQuiz->createQuiz($_POST['quizTitle'], $_POST['quizState'], $_POST['quizDescription'], $ObjClass->convertUUIDToClassID($_POST['classid']));
if ($createContent !== false) {
$responseMsg = "Your quiz has been created successfully";
} else {
$responseMsg = "Could not create your quiz at this time - something went wrong, sorry";
}
}
// create the view for coursek information
require_once 'web/core/quiz/create.php';
} else {
require_once 'web/core/security/insufficientrights.php';
}
} else {
require_once 'web/core/login/index.php';
}