Basic class for all assessment question types. More...
Inheritance diagram for ASS_Question:Public Member Functions | |
| ASS_Question ($title="", $comment="", $author="", $owner=-1) | |
| ASS_Question constructor. | |
| _ASS_Question () | |
| to_xml () | |
| Returns a QTI xml representation of the question. | |
| isComplete () | |
| Returns true, if a question is complete for use. | |
| questionTitleExists ($title) | |
| Returns TRUE if the question title exists in the database. | |
| setTitle ($title="") | |
| Sets the title string. | |
| setId ($id=-1) | |
| Sets the id. | |
| setTestId ($id=-1) | |
| Sets the test id. | |
| setComment ($comment="") | |
| Sets the comment. | |
| setOutputType ($outputType=OUTPUT_HTML) | |
| Sets the output type. | |
| setShuffle ($shuffle=true) | |
| Sets the shuffle flag. | |
| setEstimatedWorkingTime ($hour=0, $min=0, $sec=0) | |
| Sets the estimated working time of a question. | |
| keyInArray ($searchkey, $array) | |
| returns TRUE if the key occurs in an array | |
| setAuthor ($author="") | |
| Sets the authors name. | |
| setOwner ($owner="") | |
| Sets the creator/owner. | |
| getTitle () | |
| Gets the title string. | |
| getId () | |
| Gets the id. | |
| getShuffle () | |
| Gets the shuffle flag. | |
| getTestId () | |
| Gets the test id. | |
| getComment () | |
| Gets the comment. | |
| getOutputType () | |
| Gets the output type. | |
| getEstimatedWorkingTime () | |
| Gets the estimated working time of a question. | |
| getAuthor () | |
| Gets the authors name. | |
| getOwner () | |
| Gets the creator/owner. | |
| getObjId () | |
| Get the object id of the container object. | |
| setObjId ($obj_id=0) | |
| Set the object id of the container object. | |
| createPageObject () | |
| create page object of question | |
| insertIntoTest ($test_id) | |
| Insert the question into a test. | |
| _getMaximumPoints ($question_id) | |
| Returns the maximum points, a learner can reach answering the question. | |
| & | _getQuestionInfo ($question_id) |
| Returns question information from the database. | |
| _getSuggestedSolutionCount ($question_id) | |
| Returns the number of suggested solutions associated with a question. | |
| & | _getSuggestedSolution ($question_id, $subquestion_index=0) |
| Returns a suggested solution for a given subquestion index. | |
| _getReachedPoints ($user_id, $test_id, $question_id) | |
| Returns the points, a learner has reached answering the question. | |
| getReachedPoints ($user_id, $test_id) | |
| Returns the points, a learner has reached answering the question. | |
| getMaximumPoints () | |
| Returns the maximum points, a learner can reach answering the question. | |
| saveWorkingData ($test_id, $limit_to=LIMIT_NO_LIMIT) | |
| Saves the learners input of the question to the database. | |
| getJavaPath () | |
| Returns the image path for web accessable images of a question. | |
| getImagePath () | |
| Returns the image path for web accessable images of a question. | |
| getJavaPathWeb () | |
| Returns the web image path for web accessable java applets of a question. | |
| getImagePathWeb () | |
| Returns the web image path for web accessable images of a question. | |
| & | getSolutionValues ($test_id, $ilUser) |
| Loads solutions of the active user from the database an returns it. | |
| isInUse ($question_id="") | |
| Checks whether the question is in use or not. | |
| isClone ($question_id="") | |
| Checks whether the question is a clone of another question or not. | |
| pcArrayShuffle ($array) | |
| Shuffles the values of a given array. | |
| getQuestionTypeFromDb ($question_id) | |
| get question type for question id | |
| delete ($question_id) | |
| Deletes a question from the database. | |
| getTotalAnswers () | |
| get total number of answers | |
| _getTotalAnswers ($a_q_id) | |
| get number of answers for question id (static) note: do not use $this inside this method | |
| _getTotalRightAnswers ($a_q_id) | |
| get number of answers for question id (static) note: do not use $this inside this method | |
| _getTitle ($a_q_id) | |
| Returns the title of a question. | |
| copyPageOfQuestion ($a_q_id) | |
| getPageOfQuestion () | |
| _getQuestionType ($question_id) | |
| Returns the question type of a question with a given id. | |
| _getQuestionTitle ($question_id) | |
| Returns the question title of a question with a given id. | |
| loadFromDb ($question_id) | |
| Loads the question from the database. | |
| saveToDb ($original_id="") | |
| Saves the question to the database. | |
| deleteSuggestedSolutions () | |
| Deletes all suggestes solutions in the database. | |
| getSuggestedSolution ($subquestion_index=0) | |
| Returns a suggested solution for a given subquestion index. | |
| getSuggestedSolutionTitle ($subquestion_index=0) | |
| Returns the title of a suggested solution at a given subquestion_index. | |
| setSuggestedSolution ($solution_id="", $subquestion_index=0, $is_import=false) | |
| Sets a suggested solution for the question. | |
| _resolveInternalLink ($internal_link) | |
| _resolveIntLinks ($question_id) | |
| _getInternalLinkHref ($target="") | |
| _getOriginalId ($question_id) | |
| Returns the original id of a question. | |
| syncWithOriginal () | |
| createRandomSolution ($test_id, $user_id) | |
| _questionExists ($question_id) | |
| Returns true if the question already exists in the database. | |
| _isWriteable ($question_id, $user_id) | |
| Returns true if the question is writeable by a certain user. | |
| & | _instanciateQuestion ($question_id) |
| Creates an instance of a question with a given question id. | |
| getPoints () | |
| Returns the maximum available points for the question. | |
| setPoints ($a_points) | |
| Sets the maximum available points for the question. | |
| getSolutionCommentMCScoring ($test_id) | |
| getSolutionCommentCountSystem ($test_id) | |
| _isUsedInRandomTest ($question_id="") | |
| Checks whether the question is used in a random test or not. | |
Data Fields | |
| $id | |
| $title | |
| $comment | |
| $owner | |
| $author | |
| $points | |
| $est_working_time | |
| $shuffle | |
| $test_id | |
| $obj_id | |
| $ilias | |
| $tpl | |
| $lng | |
| $domxml | |
| $outputType | |
| $suggested_solutions | |
Basic class for all assessment question types.
The ASS_Question class defines and encapsulates basic methods and attributes for assessment question types to be used for all parent classes.
class.assQuestion.php Assessment
Definition at line 50 of file class.assQuestion.php.
| ASS_Question::_ASS_Question | ( | ) |
Definition at line 239 of file class.assQuestion.php.
{
if (!empty($this->domxml))
{
$this->domxml->free();
}
}
| ASS_Question::_getInternalLinkHref | ( | $ | target = "" |
) |
Definition at line 1538 of file class.assQuestion.php.
References $target_id, $type, and ilUtil::removeTrailingPathSeparators().
Referenced by ASS_TextQuestionGUI::editQuestion(), ASS_OrderingQuestionGUI::editQuestion(), ASS_MultipleChoiceGUI::editQuestion(), ASS_MatchingQuestionGUI::editQuestion(), ASS_JavaAppletGUI::editQuestion(), ASS_ImagemapQuestionGUI::editQuestion(), ASS_ClozeTestGUI::editQuestion(), and ilObjTest::getTestResult().
{
global $ilDB;
$linktypes = array(
"lm" => "LearningModule",
"pg" => "PageObject",
"st" => "StructureObject",
"git" => "GlossaryItem",
"mob" => "MediaObject"
);
$href = "";
if (preg_match("/il__(\w+)_(\d+)/", $target, $matches))
{
$type = $matches[1];
$target_id = $matches[2];
switch($linktypes[$matches[1]])
{
case "LearningModule":
$href = ilUtil::removeTrailingPathSeparators(ILIAS_HTTP_PATH) ."/goto.php?target=" . $type . "_" . $target_id;
break;
case "PageObject":
case "StructureObject":
$href = ilUtil::removeTrailingPathSeparators(ILIAS_HTTP_PATH) ."/goto.php?target=" . $type . "_" . $target_id;
break;
case "GlossaryItem":
$href = ilUtil::removeTrailingPathSeparators(ILIAS_HTTP_PATH) ."/goto.php?target=" . $type . "_" . $target_id;
break;
case "MediaObject":
$href = ilUtil::removeTrailingPathSeparators(ILIAS_HTTP_PATH) . "/content/lm_presentation.php?obj_type=" . $linktypes[$type] . "&cmd=media&ref_id=".$_GET["ref_id"]."&mob_id=".$target_id;
break;
}
}
return $href;
}
Here is the call graph for this function:
Here is the caller graph for this function:| ASS_Question::_getMaximumPoints | ( | $ | question_id | ) |
Returns the maximum points, a learner can reach answering the question.
Returns the maximum points, a learner can reach answering the question
| integer | $question_id The database Id of the question public |
Definition at line 680 of file class.assQuestion.php.
References $points, $query, $result, and $row.
Referenced by _getTotalRightAnswers(), and ilObjTest::getTestResult().
{
global $ilDB;
$points = 0;
$query = sprintf("SELECT points FROM qpl_questions WHERE question_id = %s",
$ilDB->quote($question_id . "")
);
$result = $ilDB->query($query);
if ($result->numRows() == 1)
{
$row = $result->fetchRow(DB_FETCHMODE_ASSOC);
$points = $row["points"];
}
return $points;
}
Here is the caller graph for this function:| ASS_Question::_getOriginalId | ( | $ | question_id | ) |
Returns the original id of a question.
Returns the original id of a question
| integer | $question_id The database id of the question |
Definition at line 1582 of file class.assQuestion.php.
References $query, $result, and $row.
Referenced by ilObjTest::_clone(), ASS_TextQuestion::duplicate(), ASS_OrderingQuestion::duplicate(), ASS_MultipleChoice::duplicate(), ASS_MatchingQuestion::duplicate(), ASS_JavaApplet::duplicate(), ASS_ImagemapQuestion::duplicate(), ASS_ClozeTest::duplicate(), and ilObjTest::logAction().
{
global $ilDB;
$query = sprintf("SELECT * FROM qpl_questions WHERE question_id = %s",
$ilDB->quote($question_id . "")
);
$result = $ilDB->query($query);
if ($result->numRows() > 0)
{
$row = $result->fetchRow(DB_FETCHMODE_ASSOC);
if ($row["original_id"] > 0)
{
return $row["original_id"];
}
else
{
return $row["question_id"];
}
}
else
{
return "";
}
}
Here is the caller graph for this function:| & ASS_Question::_getQuestionInfo | ( | $ | question_id | ) |
Returns question information from the database.
Returns question information from the database
| integer | $question_id The database Id of the question |
Definition at line 706 of file class.assQuestion.php.
References $query, and $result.
Referenced by ilObjTest::getTestResult().
{
global $ilDB;
$query = sprintf("SELECT qpl_questions.*, qpl_question_type.type_tag FROM qpl_question_type, qpl_questions WHERE qpl_questions.question_id = %s AND qpl_questions.question_type_fi = qpl_question_type.question_type_id",
$ilDB->quote($question_id . "")
);
$result = $ilDB->query($query);
if ($result->numRows())
{
return $result->fetchRow(DB_FETCHMODE_ASSOC);
}
else return array();
}
Here is the caller graph for this function:| ASS_Question::_getQuestionTitle | ( | $ | question_id | ) |
Returns the question title of a question with a given id.
Returns the question title of a question with a given id
| integer | $question_id The database id of the question |
Definition at line 1281 of file class.assQuestion.php.
References $data, $query, and $result.
Referenced by ilObjAssessmentFolderGUI::logsObject().
{
global $ilDB;
if ($question_id < 1)
return "";
$query = sprintf("SELECT title FROM qpl_questions WHERE qpl_questions.question_id = %s",
$ilDB->quote($question_id)
);
$result = $ilDB->query($query);
if ($result->numRows() == 1) {
$data = $result->fetchRow(DB_FETCHMODE_ASSOC);
return $data["title"];
} else {
return "";
}
}
Here is the caller graph for this function:| ASS_Question::_getQuestionType | ( | $ | question_id | ) |
Returns the question type of a question with a given id.
Returns the question type of a question with a given id
| integer | $question_id The database id of the question |
Definition at line 1254 of file class.assQuestion.php.
References $data, $query, and $result.
Referenced by ilObjTest::_instanciateQuestion(), and _instanciateQuestion().
{
global $ilDB;
if ($question_id < 1)
return "";
$query = sprintf("SELECT type_tag FROM qpl_questions, qpl_question_type WHERE qpl_questions.question_id = %s AND qpl_questions.question_type_fi = qpl_question_type.question_type_id",
$ilDB->quote($question_id)
);
$result = $ilDB->query($query);
if ($result->numRows() == 1) {
$data = $result->fetchRow(DB_FETCHMODE_OBJECT);
return $data->type_tag;
} else {
return "";
}
}
Here is the caller graph for this function:| ASS_Question::_getReachedPoints | ( | $ | user_id, | |
| $ | test_id, | |||
| $ | question_id | |||
| ) |
Returns the points, a learner has reached answering the question.
Returns the points, a learner has reached answering the question
| integer | $user_id The database ID of the learner | |
| integer | $test_id The database Id of the test containing the question | |
| integer | $question_id The database Id of the question public static |
Definition at line 784 of file class.assQuestion.php.
References $points, $query, $result, $row, $test_id, and $user_id.
Referenced by ilObjTest::getTestResult().
{
global $ilDB;
$points = 0;
$query = sprintf("SELECT * FROM tst_test_result WHERE user_fi = %s AND test_fi = %s AND question_fi = %s",
$ilDB->quote($user_id . ""),
$ilDB->quote($test_id . ""),
$ilDB->quote($question_id . "")
);
$result = $ilDB->query($query);
if ($result->numRows() == 1)
{
$row = $result->fetchRow(DB_FETCHMODE_ASSOC);
$points = $row["points"];
}
return $points;
}
Here is the caller graph for this function:| & ASS_Question::_getSuggestedSolution | ( | $ | question_id, | |
| $ | subquestion_index = 0 | |||
| ) |
Returns a suggested solution for a given subquestion index.
Returns a suggested solution for a given subquestion index
| integer | $question_id The database Id of the question | |
| integer | $subquestion_index The index of a subquestion (i.e. a close test gap). Usually 0 |
Definition at line 751 of file class.assQuestion.php.
References $query, $result, and $row.
Referenced by ilObjTest::getTestResult().
{
global $ilDB;
$query = sprintf("SELECT * FROM qpl_suggested_solutions WHERE question_fi = %s AND subquestion_index = %s",
$ilDB->quote($question_id . ""),
$ilDB->quote($subquestion_index . "")
);
$result = $ilDB->query($query);
if ($result->numRows() == 1)
{
$row = $result->fetchRow(DB_FETCHMODE_ASSOC);
return array(
"internal_link" => $row["internal_link"],
"import_id" => $row["import_id"]
);
}
else
{
return array();
}
}
Here is the caller graph for this function:| ASS_Question::_getSuggestedSolutionCount | ( | $ | question_id | ) |
Returns the number of suggested solutions associated with a question.
Returns the number of suggested solutions associated with a question
| integer | $question_id The database Id of the question |
Definition at line 730 of file class.assQuestion.php.
References $query, and $result.
Referenced by ilObjTest::getTestResult().
{
global $ilDB;
$query = sprintf("SELECT suggested_solution_id FROM qpl_suggested_solutions WHERE question_fi = %s",
$ilDB->quote($question_id . "")
);
$result = $ilDB->query($query);
return $result->numRows();
}
Here is the caller graph for this function:| ASS_Question::_getTitle | ( | $ | a_q_id | ) |
Returns the title of a question.
| int | $a_q_id question id |
Definition at line 1207 of file class.assQuestion.php.
References $query, $result, and $row.
Referenced by ilObjQuestionPoolGUI::assessmentObject().
{
global $ilDB;
$query = sprintf("SELECT title FROM qpl_questions WHERE question_id = %s",
$ilDB->quote($a_q_id)
);
$result = $ilDB->query($query);
if ($result->numRows() == 1)
{
$row = $result->fetchRow(DB_FETCHMODE_ASSOC);
return $row["title"];
}
else
{
return "";
}
}
Here is the caller graph for this function:| ASS_Question::_getTotalAnswers | ( | $ | a_q_id | ) |
get number of answers for question id (static) note: do not use $this inside this method
| int | $a_q_id question id |
Definition at line 1113 of file class.assQuestion.php.
References $query, $result, and $row.
Referenced by ilObjQuestionPoolGUI::assessmentObject(), and getTotalAnswers().
{
global $ilDB;
// get all question references to the question id
$query = sprintf("SELECT question_id FROM qpl_questions WHERE original_id = %s OR question_id = %s",
$ilDB->quote($a_q_id),
$ilDB->quote($a_q_id)
);
$result = $ilDB->query($query);
if ($result->numRows() == 0)
{
return 0;
}
$found_id = array();
while ($row = $result->fetchRow(DB_FETCHMODE_OBJECT))
{
array_push($found_id, $row->question_id);
}
$query = sprintf("SELECT * FROM tst_test_result WHERE question_fi IN (%s)",
join($found_id, ","));
$result = $ilDB->query($query);
/* $query = sprintf("SELECT * FROM tst_solutions WHERE question_fi IN (%s) GROUP BY CONCAT(user_fi,test_fi)",
join($found_id, ","));
$result = $ilDB->query($query);
*/
return $result->numRows();
}
Here is the caller graph for this function:| ASS_Question::_getTotalRightAnswers | ( | $ | a_q_id | ) |
get number of answers for question id (static) note: do not use $this inside this method
| int | $a_q_id question id |
Definition at line 1154 of file class.assQuestion.php.
References $query, $result, $row, and _getMaximumPoints().
Referenced by ilObjQuestionPoolGUI::assessmentObject().
{
global $ilDB;
$query = sprintf("SELECT question_id FROM qpl_questions WHERE original_id = %s OR question_id = %s",
$ilDB->quote($a_q_id),
$ilDB->quote($a_q_id)
);
$result = $ilDB->query($query);
if ($result->numRows() == 0)
{
return 0;
}
$found_id = array();
while ($row = $result->fetchRow(DB_FETCHMODE_OBJECT))
{
array_push($found_id, $row->question_id);
}
$query = sprintf("SELECT * FROM tst_test_result WHERE question_fi IN (%s)",
join($found_id, ","));
$result = $ilDB->query($query);
/* $query = sprintf("SELECT * FROM tst_solutions WHERE question_fi IN (%s) GROUP BY CONCAT(user_fi,test_fi)",
join($found_id, ",")
);
$result = $ilDB->query($query);*/
$answers = array();
while ($row = $result->fetchRow(DB_FETCHMODE_OBJECT))
{
$reached = $row->points; //ASS_Question::_getReachedPoints($row->user_fi, $row->test_fi, $row->question_fi);
$max = ASS_Question::_getMaximumPoints($row->question_fi);
array_push($answers, array("reached" => $reached, "max" => $max));
}
$max = 0.0;
$reached = 0.0;
foreach ($answers as $key => $value)
{
$max += $value["max"];
$reached += $value["reached"];
}
if ($max > 0)
{
return $reached / $max;
}
else
{
return 0;
}
}
Here is the call graph for this function:
Here is the caller graph for this function:| & ASS_Question::_instanciateQuestion | ( | $ | question_id | ) |
Creates an instance of a question with a given question id.
Creates an instance of a question with a given question id
| integer | $question_id The question id |
Definition at line 1712 of file class.assQuestion.php.
References _getQuestionType().
{
if (strcmp($question_id, "") != 0)
{
$question_type = ASS_Question::_getQuestionType($question_id);
switch ($question_type) {
case "qt_cloze":
$question = new ASS_ClozeTest();
break;
case "qt_matching":
$question = new ASS_MatchingQuestion();
break;
case "qt_ordering":
$question = new ASS_OrderingQuestion();
break;
case "qt_imagemap":
$question = new ASS_ImagemapQuestion();
break;
case "qt_multiple_choice_sr":
case "qt_multiple_choice_mr":
$question = new ASS_MultipleChoice();
break;
case "qt_javaapplet":
$question = new ASS_JavaApplet();
break;
case "qt_text":
$question = new ASS_TextQuestion();
break;
}
$question->loadFromDb($question_id);
return $question;
}
}
Here is the call graph for this function:| ASS_Question::_isUsedInRandomTest | ( | $ | question_id = "" |
) |
Checks whether the question is used in a random test or not.
Checks whether the question is used in a random test or not
Definition at line 1809 of file class.assQuestion.php.
References $query, and $result.
Referenced by ilObjQuestionPool::getDeleteableQuestionDetails(), and ilObjQuestionPool::getUsedQuestionDetails().
{
global $ilDB;
if ($question_id < 1) return 0;
$query = sprintf("SELECT test_random_question_id FROM tst_test_random_question WHERE question_fi = %s",
$ilDB->quote($question_id . "")
);
$result = $ilDB->query($query);
return $result->numRows();
}
Here is the caller graph for this function:| ASS_Question::_isWriteable | ( | $ | question_id, | |
| $ | user_id | |||
| ) |
Returns true if the question is writeable by a certain user.
Returns true if the question is writeable by a certain user
| integer | $question_id The database id of the question | |
| integer | $user_id The database id of the user |
Definition at line 1677 of file class.assQuestion.php.
References $query, $result, $row, and $user_id.
Referenced by ASS_QuestionGUI::save(), and ASS_QuestionGUI::saveEdit().
{
global $ilDB;
if (($question_id < 1) || ($user_id < 1))
{
return false;
}
$query = sprintf("SELECT obj_fi FROM qpl_questions WHERE question_id = %s",
$ilDB->quote($question_id . "")
);
$result = $ilDB->query($query);
if ($result->numRows() == 1)
{
$row = $result->fetchRow(DB_FETCHMODE_ASSOC);
$qpl_object_id = $row["obj_fi"];
include_once "./assessment/classes/class.ilObjQuestionPool.php";
return ilObjQuestionPool::_isWriteable($qpl_object_id, $user_id);
}
else
{
return false;
}
}
Here is the caller graph for this function:| ASS_Question::_questionExists | ( | $ | question_id | ) |
Returns true if the question already exists in the database.
Returns true if the question already exists in the database
| integer | $question_id The database id of the question |
Definition at line 1644 of file class.assQuestion.php.
| ASS_Question::_resolveInternalLink | ( | $ | internal_link | ) |
Definition at line 1450 of file class.assQuestion.php.
References ilInternalLink::_getIdForImportId(), and ilLMObject::_getIdForImportId().
Referenced by _resolveIntLinks(), and setSuggestedSolution().
{
if (preg_match("/il_(\d+)_(\w+)_(\d+)/", $internal_link, $matches))
{
require_once "./content/classes/Pages/class.ilInternalLink.php";
require_once "./content/classes/class.ilLMObject.php";
require_once "./content/classes/class.ilGlossaryTerm.php";
switch ($matches[2])
{
case "lm":
$resolved_link = ilLMObject::_getIdForImportId($internal_link);
break;
case "pg":
$resolved_link = ilInternalLink::_getIdForImportId("PageObject", $internal_link);
break;
case "st":
$resolved_link = ilInternalLink::_getIdForImportId("StructureObject", $internal_link);
break;
case "git":
$resolved_link = ilInternalLink::_getIdForImportId("GlossaryItem", $internal_link);
break;
case "mob":
$resolved_link = ilInternalLink::_getIdForImportId("MediaObject", $internal_link);
break;
}
if (strcmp($resolved_link, "") == 0)
{
$resolved_link = $internal_link;
}
}
else
{
$resolved_link = $internal_link;
}
return $resolved_link;
}
Here is the call graph for this function:
Here is the caller graph for this function:| ASS_Question::_resolveIntLinks | ( | $ | question_id | ) |
Definition at line 1487 of file class.assQuestion.php.
References $query, $result, $row, ilInternalLink::_deleteAllLinksOfSource(), _resolveInternalLink(), and ilInternalLink::_saveLink().
Referenced by ilContObjParser::processPagesToParse().
{
global $ilDB;
$resolvedlinks = 0;
$query = sprintf("SELECT * FROM qpl_suggested_solutions WHERE question_fi = %s",
$ilDB->quote($question_id . "")
);
$result = $ilDB->query($query);
if ($result->numRows())
{
while ($row = $result->fetchRow(DB_FETCHMODE_ASSOC))
{
$internal_link = $row["internal_link"];
$resolved_link = ASS_Question::_resolveInternalLink($internal_link);
if (strcmp($internal_link, $resolved_link) != 0)
{
// internal link was resolved successfully
$queryupdate = sprintf("UPDATE qpl_suggested_solutions SET internal_link = %s WHERE suggested_solution_id = %s",
$ilDB->quote($resolved_link),
$ilDB->quote($row["suggested_solution_id"] . "")
);
$updateresult = $ilDB->query($queryupdate);
$resolvedlinks++;
}
}
}
if ($resolvedlinks)
{
// there are resolved links -> reenter theses links to the database
// delete all internal links from the database
require_once "./content/classes/Pages/class.ilInternalLink.php";
ilInternalLink::_deleteAllLinksOfSource("qst", $question_id);
$query = sprintf("SELECT * FROM qpl_suggested_solutions WHERE question_fi = %s",
$ilDB->quote($question_id . "")
);
$result = $ilDB->query($query);
if ($result->numRows())
{
while ($row = $result->fetchRow(DB_FETCHMODE_ASSOC))
{
if (preg_match("/il_(\d*?)_(\w+)_(\d+)/", $row["internal_link"], $matches))
{
ilInternalLink::_saveLink("qst", $question_id, $matches[2], $matches[3], $matches[1]);
}
}
}
}
}
Here is the call graph for this function:
Here is the caller graph for this function:| ASS_Question::ASS_Question | ( | $ | title = "", |
|
| $ | comment = "", |
|||
| $ | author = "", |
|||
| $ | owner = -1 | |||
| ) |
ASS_Question constructor.
The constructor takes possible arguments an creates an instance of the ASS_Question object.
| string | $title A title string to describe the question | |
| string | $comment A comment string to describe the question | |
| string | $author A string containing the name of the questions author | |
| integer | $owner A numerical ID to identify the owner/creator public |
Definition at line 203 of file class.assQuestion.php.
References $author, $comment, $ilias, $lng, $owner, $title, $tpl, and setEstimatedWorkingTime().
Referenced by ASS_ClozeTest::ASS_ClozeTest(), ASS_ImagemapQuestion::ASS_ImagemapQuestion(), ASS_JavaApplet::ASS_JavaApplet(), ASS_MatchingQuestion::ASS_MatchingQuestion(), ASS_MultipleChoice::ASS_MultipleChoice(), ASS_OrderingQuestion::ASS_OrderingQuestion(), and ASS_TextQuestion::ASS_TextQuestion().
{
global $ilias;
global $lng;
global $tpl;
$this->ilias =& $ilias;
$this->lng =& $lng;
$this->tpl =& $tpl;
$this->title = $title;
$this->comment = $comment;
$this->author = $author;
if (!$this->author)
{
$this->author = $this->ilias->account->fullname;
}
$this->owner = $owner;
if ($this->owner == -1)
{
$this->owner = $this->ilias->account->id;
}
$this->id = -1;
$this->test_id = -1;
$this->suggested_solutions = array();
$this->shuffle = 1;
$this->setEstimatedWorkingTime(0,1,0);
$this->outputType = OUTPUT_HTML;
register_shutdown_function(array(&$this, '_ASS_Question'));
}
Here is the call graph for this function:
Here is the caller graph for this function:| ASS_Question::copyPageOfQuestion | ( | $ | a_q_id | ) |
Definition at line 1225 of file class.assQuestion.php.
References $xml.
{
if ($a_q_id > 0)
{
$page = new ilPageObject("qpl", $a_q_id);
$xml = str_replace("il__qst_".$a_q_id, "il__qst_".$this->id,
$page->getXMLContent());
$this->page->setXMLContent($xml);
$this->page->saveMobUsage($xml);
$this->page->updateFromXML();
}
}
| ASS_Question::createPageObject | ( | ) |
create page object of question
Definition at line 624 of file class.assQuestion.php.
References getId(), and getObjId().
Referenced by ASS_TextQuestion::saveToDb(), ASS_OrderingQuestion::saveToDb(), ASS_MultipleChoice::saveToDb(), ASS_MatchingQuestion::saveToDb(), ASS_JavaApplet::saveToDb(), ASS_ImagemapQuestion::saveToDb(), and ASS_ClozeTest::saveToDb().
{
// $qpl_id = ilObject::_lookupObjectId($this->getRefId());
$qpl_id = $this->getObjId();
$this->page = new ilPageObject("qpl", 0);
$this->page->setId($this->getId());
$this->page->setParentId($qpl_id);
$this->page->setXMLContent("<PageObject><PageContent>".
"<Question QRef=\"il__qst_".$this->getId()."\"/>".
"</PageContent></PageObject>");
$this->page->create();
}
Here is the call graph for this function:
Here is the caller graph for this function:| ASS_Question::createRandomSolution | ( | $ | test_id, | |
| $ | user_id | |||
| ) |
Reimplemented in ASS_MatchingQuestion, ASS_MultipleChoice, ASS_OrderingQuestion, and ASS_TextQuestion.
Definition at line 1631 of file class.assQuestion.php.
{
}
| ASS_Question::delete | ( | $ | question_id | ) |
Deletes a question from the database.
Deletes a question and all materials from the database
| integer | $question_id The database id of the question private |
Definition at line 1052 of file class.assQuestion.php.
References $obj_id, $query, $result, and $row.
{
if ($question_id < 1)
return;
$query = sprintf("SELECT obj_fi FROM qpl_questions WHERE question_id = %s",
$this->ilias->db->quote($question_id)
);
$result = $this->ilias->db->query($query);
if ($result->numRows() == 1)
{
$row = $result->fetchRow(DB_FETCHMODE_ASSOC);
$obj_id = $row["obj_fi"];
}
else
{
return;
}
$page = new ilPageObject("qpl", $question_id);
$page->delete();
$query = sprintf("DELETE FROM qpl_questions WHERE question_id = %s",
$this->ilias->db->quote($question_id)
);
$result = $this->ilias->db->query($query);
$query = sprintf("DELETE FROM qpl_answers WHERE question_fi = %s",
$this->ilias->db->quote($question_id)
);
$result = $this->ilias->db->query($query);
// delete the question in the tst_test_question table (list of test questions)
$querydelete = sprintf("DELETE FROM tst_test_question WHERE question_fi = %s", $this->ilias->db->quote($question_id));
$deleteresult = $this->ilias->db->query($querydelete);
// delete suggested solutions contained in the question
$querydelete = sprintf("DELETE FROM qpl_suggested_solutions WHERE question_fi = %s", $this->ilias->db->quote($question_id));
$deleteresult = $this->ilias->db->query($querydelete);
$directory = CLIENT_WEB_DIR . "/assessment/" . $obj_id . "/$question_id";
if (preg_match("/\d+/", $obj_id) and preg_match("/\d+/", $question_id) and is_dir($directory))
{
$directory = escapeshellarg($directory);
exec("rm -rf $directory");
}
}
| ASS_Question::deleteSuggestedSolutions | ( | ) |
Deletes all suggestes solutions in the database.
Deletes all suggestes solutions in the database
public
Definition at line 1365 of file class.assQuestion.php.
References $query, $result, ilInternalLink::_deleteAllLinksOfSource(), and getId().
{
// delete the links in the qpl_suggested_solutions table
$query = sprintf("DELETE FROM qpl_suggested_solutions WHERE question_fi = %s",
$this->ilias->db->quote($this->getId() . "")
);
$result = $this->ilias->db->query($query);
// delete the links in the int_link table
require_once "./content/classes/Pages/class.ilInternalLink.php";
ilInternalLink::_deleteAllLinksOfSource("qst", $this->getId());
}
Here is the call graph for this function:| ASS_Question::getAuthor | ( | ) |
Gets the authors name.
Gets the authors name of the ASS_Question object
Definition at line 574 of file class.assQuestion.php.
Referenced by ASS_TextQuestion::to_xml(), ASS_OrderingQuestion::to_xml(), ASS_MultipleChoice::to_xml(), ASS_MatchingQuestion::to_xml(), ASS_JavaApplet::to_xml(), ASS_ImagemapQuestion::to_xml(), and ASS_ClozeTest::to_xml().
{
return $this->author;
}
Here is the caller graph for this function:| ASS_Question::getComment | ( | ) |
Gets the comment.
Gets the comment string of the ASS_Question object
Definition at line 528 of file class.assQuestion.php.
Referenced by ASS_TextQuestion::to_xml(), ASS_OrderingQuestion::to_xml(), ASS_MultipleChoice::to_xml(), ASS_MatchingQuestion::to_xml(), ASS_JavaApplet::to_xml(), ASS_ImagemapQuestion::to_xml(), and ASS_ClozeTest::to_xml().
{
return $this->comment;
}
Here is the caller graph for this function:| ASS_Question::getEstimatedWorkingTime | ( | ) |
Gets the estimated working time of a question.
Gets the estimated working time of a question
Definition at line 556 of file class.assQuestion.php.
Referenced by ASS_TextQuestion::saveToDb(), ASS_OrderingQuestion::saveToDb(), ASS_MultipleChoice::saveToDb(), ASS_MatchingQuestion::saveToDb(), ASS_JavaApplet::saveToDb(), ASS_ImagemapQuestion::saveToDb(), ASS_ClozeTest::saveToDb(), ASS_TextQuestion::syncWithOriginal(), ASS_OrderingQuestion::syncWithOriginal(), ASS_MultipleChoice::syncWithOriginal(), ASS_MatchingQuestion::syncWithOriginal(), ASS_JavaApplet::syncWithOriginal(), ASS_ImagemapQuestion::syncWithOriginal(), ASS_ClozeTest::syncWithOriginal(), ASS_TextQuestion::to_xml(), ASS_OrderingQuestion::to_xml(), ASS_MultipleChoice::to_xml(), ASS_MatchingQuestion::to_xml(), ASS_JavaApplet::to_xml(), ASS_ImagemapQuestion::to_xml(), and ASS_ClozeTest::to_xml().
{
if (!$this->est_working_time)
{
$this->est_working_time = array("h" => 0, "m" => 0, "s" => 0);
}
return $this->est_working_time;
}
Here is the caller graph for this function:| ASS_Question::getId | ( | ) |
Gets the id.
Gets the id of the ASS_Question object
Definition at line 486 of file class.assQuestion.php.
Referenced by ASS_TextQuestion::calculateReachedPoints(), ASS_OrderingQuestion::calculateReachedPoints(), ASS_MultipleChoice::calculateReachedPoints(), ASS_MatchingQuestion::calculateReachedPoints(), ASS_JavaApplet::calculateReachedPoints(), ASS_ImagemapQuestion::calculateReachedPoints(), ASS_ClozeTest::calculateReachedPoints(), createPageObject(), ASS_OrderingQuestion::createRandomSolution(), ASS_MultipleChoice::createRandomSolution(), ASS_MatchingQuestion::createRandomSolution(), deleteSuggestedSolutions(), ASS_TextQuestion::from_xml(), ASS_OrderingQuestion::from_xml(), ASS_MultipleChoice::from_xml(), ASS_MatchingQuestion::from_xml(), ASS_JavaApplet::from_xml(), ASS_ImagemapQuestion::from_xml(), ASS_ClozeTest::from_xml(), ASS_TextQuestion::getReachedInformation(), ASS_OrderingQuestion::getReachedInformation(), ASS_MultipleChoice::getReachedInformation(), ASS_MatchingQuestion::getReachedInformation(), ASS_JavaApplet::getReachedInformation(), ASS_ImagemapQuestion::getReachedInformation(), ASS_ClozeTest::getReachedInformation(), getReachedPoints(), getSolutionValues(), insertIntoTest(), saveToDb(), ASS_TextQuestion::saveWorkingData(), saveWorkingData(), ASS_OrderingQuestion::saveWorkingData(), ASS_MultipleChoice::saveWorkingData(), ASS_MatchingQuestion::saveWorkingData(), ASS_ImagemapQuestion::saveWorkingData(), ASS_ClozeTest::saveWorkingData(), ASS_TextQuestion::setReachedPoints(), ASS_JavaApplet::to_xml(), and ASS_MultipleChoice::wasAnsweredByUser().
{
return $this->id;
}
Here is the caller graph for this function:| ASS_Question::getImagePath | ( | ) |
Returns the image path for web accessable images of a question.
Returns the image path for web accessable images of a question. The image path is under the CLIENT_WEB_DIR in assessment/REFERENCE_ID_OF_QUESTION_POOL/ID_OF_QUESTION/images
public
Definition at line 889 of file class.assQuestion.php.
Referenced by ASS_ImagemapQuestion::duplicateImage(), ASS_OrderingQuestion::duplicateImages(), ASS_MatchingQuestion::duplicateImages(), ASS_OrderingQuestion::from_xml(), ASS_MatchingQuestion::from_xml(), ASS_ImagemapQuestion::from_xml(), ASS_OrderingQuestion::set_image_file(), ASS_MatchingQuestion::set_image_file(), ASS_ImagemapQuestion::set_image_filename(), ASS_OrderingQuestion::to_xml(), ASS_MatchingQuestion::to_xml(), and ASS_ImagemapQuestion::to_xml().
{
return CLIENT_WEB_DIR . "/assessment/$this->obj_id/$this->id/images/";
}
Here is the caller graph for this function:| ASS_Question::getImagePathWeb | ( | ) |
Returns the web image path for web accessable images of a question.
Returns the web image path for web accessable images of a question. The image path is under the web accessable data dir in assessment/REFERENCE_ID_OF_QUESTION_POOL/ID_OF_QUESTION/images
public
Definition at line 916 of file class.assQuestion.php.
References ilUtil::removeTrailingPathSeparators().
Referenced by ASS_OrderingQuestion::to_xml(), ASS_MatchingQuestion::to_xml(), and ASS_ImagemapQuestion::to_xml().
{
$webdir = ilUtil::removeTrailingPathSeparators(CLIENT_WEB_DIR) . "/assessment/$this->obj_id/$this->id/images/";
return str_replace(ilUtil::removeTrailingPathSeparators(ILIAS_ABSOLUTE_PATH), ilUtil::removeTrailingPathSeparators(ILIAS_HTTP_PATH), $webdir);
}
Here is the call graph for this function:
Here is the caller graph for this function:| ASS_Question::getJavaPath | ( | ) |
Returns the image path for web accessable images of a question.
Returns the image path for web accessable images of a question. The image path is under the CLIENT_WEB_DIR in assessment/REFERENCE_ID_OF_QUESTION_POOL/ID_OF_QUESTION/images
public
Definition at line 877 of file class.assQuestion.php.
Referenced by ASS_JavaApplet::duplicateApplet(), ASS_JavaApplet::from_xml(), ASS_JavaApplet::setJavaAppletFilename(), and ASS_JavaApplet::to_xml().
{
return CLIENT_WEB_DIR . "/assessment/$this->obj_id/$this->id/java/";
}
Here is the caller graph for this function:| ASS_Question::getJavaPathWeb | ( | ) |
Returns the web image path for web accessable java applets of a question.
Returns the web image path for web accessable java applets of a question. The image path is under the web accessable data dir in assessment/REFERENCE_ID_OF_QUESTION_POOL/ID_OF_QUESTION/java
public
Definition at line 902 of file class.assQuestion.php.
References ilUtil::removeTrailingPathSeparators().
{
$webdir = ilUtil::removeTrailingPathSeparators(CLIENT_WEB_DIR) . "/assessment/$this->obj_id/$this->id/java/";
return str_replace(ilUtil::removeTrailingPathSeparators(ILIAS_ABSOLUTE_PATH), ilUtil::removeTrailingPathSeparators(ILIAS_HTTP_PATH), $webdir);
}
Here is the call graph for this function:| ASS_Question::getMaximumPoints | ( | ) |
Returns the maximum points, a learner can reach answering the question.
Returns the maximum points, a learner can reach answering the question
public
Reimplemented in ASS_ClozeTest, ASS_ImagemapQuestion, ASS_JavaApplet, ASS_MatchingQuestion, ASS_MultipleChoice, ASS_OrderingQuestion, and ASS_TextQuestion.
Definition at line 840 of file class.assQuestion.php.
{
return 0;
}
| ASS_Question::getObjId | ( | ) |
Get the object id of the container object.
Get the object id of the container object
Definition at line 602 of file class.assQuestion.php.
Referenced by createPageObject().
{
return $this->obj_id;
}
Here is the caller graph for this function:| ASS_Question::getOutputType | ( | ) |
Gets the output type.
Gets the output type
Definition at line 542 of file class.assQuestion.php.
Referenced by ASS_OrderingQuestion::to_xml(), and ASS_MatchingQuestion::to_xml().
{
return $this->outputType;
}
Here is the caller graph for this function:| ASS_Question::getOwner | ( | ) |
Gets the creator/owner.
Gets the creator/owner ID of the ASS_Question object
Definition at line 588 of file class.assQuestion.php.
{
return $this->owner;
}
| ASS_Question::getPageOfQuestion | ( | ) |
Definition at line 1239 of file class.assQuestion.php.
{
$page = new ilPageObject("qpl", $this->id);
return $page->getXMLContent();
}
| ASS_Question::getPoints | ( | ) |
Returns the maximum available points for the question.
Returns the maximum available points for the question
Definition at line 1754 of file class.assQuestion.php.
Referenced by ASS_TextQuestion::saveToDb(), ASS_TextQuestion::setReachedPoints(), ASS_TextQuestion::to_xml(), and ASS_JavaApplet::to_xml().
{
if (strcmp($this->points, "") == 0)
{
return 0;
}
else
{
return $this->points;
}
}
Here is the caller graph for this function:| ASS_Question::getQuestionTypeFromDb | ( | $ | question_id | ) |
get question type for question id
note: please don't use $this in this class to allow static calls
Definition at line 1031 of file class.assQuestion.php.
References $data, $query, and $result.
Referenced by ASS_QuestionGUI::_getGUIClassNameForId(), ASS_QuestionGUI::_getQuestionGUI(), and ilObjQuestionPoolGUI::setQuestionTabs().
{
global $ilDB;
$query = sprintf("SELECT qpl_question_type.type_tag FROM qpl_question_type, qpl_questions WHERE qpl_questions.question_id = %s AND qpl_questions.question_type_fi = qpl_question_type.question_type_id",
$ilDB->quote($question_id));
$result = $ilDB->query($query);
$data = $result->fetchRow(DB_FETCHMODE_OBJECT);
return $data->type_tag;
}
Here is the caller graph for this function:| ASS_Question::getReachedPoints | ( | $ | user_id, | |
| $ | test_id | |||
| ) |
Returns the points, a learner has reached answering the question.
Returns the points, a learner has reached answering the question This is the fast way to get the points directly from the database.
| integer | $user_id The database ID of the learner | |
| integer | $test_id The database Id of the test containing the question public |
Definition at line 813 of file class.assQuestion.php.
References $points, $query, $result, $row, $test_id, $user_id, and getId().
{
global $ilDB;
$points = 0;
$query = sprintf("SELECT * FROM tst_test_result WHERE user_fi = %s AND test_fi = %s AND question_fi = %s",
$ilDB->quote($user_id),
$ilDB->quote($test_id),
$ilDB->quote($this->getId())
);
$result = $ilDB->query($query);
if ($result->numRows() == 1)
{
$row = $result->fetchRow(DB_FETCHMODE_ASSOC);
$points = $row["points"];
}
return $points;
}
Here is the call graph for this function:| ASS_Question::getShuffle | ( | ) |
Gets the shuffle flag.
Gets the shuffle flag
Definition at line 500 of file class.assQuestion.php.
Referenced by ASS_OrderingQuestion::to_xml(), ASS_MultipleChoice::to_xml(), and ASS_MatchingQuestion::to_xml().
{
return $this->shuffle;
}
Here is the caller graph for this function:| ASS_Question::getSolutionCommentCountSystem | ( | $ | test_id | ) |
Definition at line 1791 of file class.assQuestion.php.
References $result, $test_id, and ilObjTest::_getCountSystem().
{
$result = "";
include_once "./assessment/classes/class.ilObjTest.php";
if (ilObjTest::_getCountSystem($test_id) == COUNT_CORRECT_SOLUTIONS )
{
$result = $this->lng->txt("solution_comment_count_system");
}
return $result;
}
Here is the call graph for this function:| ASS_Question::getSolutionCommentMCScoring | ( | $ | test_id | ) |
Definition at line 1780 of file class.assQuestion.php.
References $result, $test_id, and ilObjTest::_getMCScoring().
{
$result = "";
include_once "./assessment/classes/class.ilObjTest.php";
if (ilObjTest::_getMCScoring($test_id) == SCORE_ZERO_POINTS_WHEN_UNANSWERED)
{
$result = $this->lng->txt("solution_comment_mc_scoring");
}
return $result;
}
Here is the call graph for this function:| & ASS_Question::getSolutionValues | ( | $ | test_id, | |
| $ | ilUser | |||
| ) |
Loads solutions of the active user from the database an returns it.
Loads solutions of the active user from the database an returns it
| integer | $test_id The database id of the test containing this question public |
Definition at line 931 of file class.assQuestion.php.
References $ilUser, $query, $result, $row, $test_id, and getId().
{
global $ilDB;
$db =& $ilDB->db;
$query = sprintf("SELECT * FROM tst_solutions WHERE user_fi = %s AND test_fi = %s AND question_fi = %s",
$db->quote($ilUser->id),
$db->quote($test_id),
$db->quote($this->getId())
);
$result = $db->query($query);
$values = array();
while ($row = $result->fetchRow(DB_FETCHMODE_OBJECT))
{
array_push($values, $row);
}
return $values;
}
Here is the call graph for this function:| ASS_Question::getSuggestedSolution | ( | $ | subquestion_index = 0 |
) |
Returns a suggested solution for a given subquestion index.
Returns a suggested solution for a given subquestion index
| integer | $subquestion_index The index of a subquestion (i.e. a close test gap). Usually 0 |
Definition at line 1386 of file class.assQuestion.php.
Referenced by ASS_TextQuestion::to_xml(), ASS_OrderingQuestion::to_xml(), ASS_MultipleChoice::to_xml(), ASS_MatchingQuestion::to_xml(), ASS_JavaApplet::to_xml(), ASS_ImagemapQuestion::to_xml(), and ASS_ClozeTest::to_xml().
{
if (array_key_exists($subquestion_index, $this->suggested_solutions))
{
return $this->suggested_solutions[$subquestion_index];
}
else
{
return array();
}
}
Here is the caller graph for this function:| ASS_Question::getSuggestedSolutionTitle | ( | $ | subquestion_index = 0 |
) |
Returns the title of a suggested solution at a given subquestion_index.
Returns the title of a suggested solution at a given subquestion_index. This can be usable for displaying suggested solutions
| integer | $subquestion_index The index of a subquestion (i.e. a close test gap). Usually 0 |
Definition at line 1408 of file class.assQuestion.php.
References $title.
| ASS_Question::getTestId | ( | ) |
Gets the test id.
Gets the test id of the ASS_Question object
Definition at line 514 of file class.assQuestion.php.
Referenced by ASS_TextQuestion::saveToDb(), ASS_OrderingQuestion::saveToDb(), ASS_MultipleChoice::saveToDb(), ASS_MatchingQuestion::saveToDb(), ASS_JavaApplet::saveToDb(), ASS_ImagemapQuestion::saveToDb(), and ASS_ClozeTest::saveToDb().
{
return $this->test_id;
}
Here is the caller graph for this function:| ASS_Question::getTitle | ( | ) |
Gets the title string.
Gets the title string of the ASS_Question object
Definition at line 472 of file class.assQuestion.php.
Referenced by ASS_TextQuestion::to_xml(), ASS_OrderingQuestion::to_xml(), ASS_MultipleChoice::to_xml(), ASS_MatchingQuestion::to_xml(), ASS_JavaApplet::to_xml(), ASS_ImagemapQuestion::to_xml(), and ASS_ClozeTest::to_xml().
{
return $this->title;
}
Here is the caller graph for this function:| ASS_Question::getTotalAnswers | ( | ) |
get total number of answers
Definition at line 1102 of file class.assQuestion.php.
References _getTotalAnswers().
{
return $this->_getTotalAnswers($this->id);
}
Here is the call graph for this function:| ASS_Question::insertIntoTest | ( | $ | test_id | ) |
Insert the question into a test.
Insert the question into a test
| integer | $test_id The database id of the test private |
Definition at line 646 of file class.assQuestion.php.
References $data, $query, $result, $test_id, and getId().
Referenced by ASS_TextQuestion::saveToDb(), ASS_OrderingQuestion::saveToDb(), ASS_MultipleChoice::saveToDb(), ASS_MatchingQuestion::saveToDb(), ASS_JavaApplet::saveToDb(), ASS_ImagemapQuestion::saveToDb(), and ASS_ClozeTest::saveToDb().
{
// get maximum sequence index in test
$query = sprintf("SELECT MAX(sequence) AS seq FROM dum_test_question WHERE test_fi=%s",
$this->ilias->db->quote($test_id)
);
$result = $this->ilias->db->query($query);
$sequence = 1;
if ($result->numRows() == 1)
{
$data = $result->fetchRow(DB_FETCHMODE_OBJECT);
$sequence = $data->seq + 1;
}
$query = sprintf("INSERT INTO dum_test_question (test_question_id, test_fi, question_fi, sequence, TIMESTAMP) VALUES (NULL, %s, %s, %s, NULL)",
$this->ilias->db->quote($test_id),
$this->ilias->db->quote($this->getId()),
$this->ilias->db->quote($sequence)
);
$result = $this->ilias->db->query($query);
if ($result != DB_OK)
{
// Fehlermeldung
}
}
Here is the call graph for this function:
Here is the caller graph for this function:| ASS_Question::isClone | ( | $ | question_id = "" |
) |
Checks whether the question is a clone of another question or not.
Checks whether the question is a clone of another question or not
Definition at line 979 of file class.assQuestion.php.
References $query, $result, and $row.
{
if ($question_id < 1) $question_id = $this->id;
$query = sprintf("SELECT original_id FROM qpl_questions WHERE question_id = %s",
$this->ilias->db->quote($question_id . "")
);
$result = $this->ilias->db->query($query);
$row = $result->fetchRow(DB_FETCHMODE_OBJECT);
if ($row->original_id > 0)
{
return TRUE;
}
else
{
return FALSE;
}
}
| ASS_Question::isComplete | ( | ) |
Returns true, if a question is complete for use.
Returns true, if a question is complete for use
Reimplemented in ASS_ClozeTest, ASS_ImagemapQuestion, ASS_JavaApplet, ASS_MatchingQuestion, ASS_MultipleChoice, ASS_OrderingQuestion, and ASS_TextQuestion.
Definition at line 269 of file class.assQuestion.php.
{
return false;
}
| ASS_Question::isInUse | ( | $ | question_id = "" |
) |
Checks whether the question is in use or not.
Checks whether the question is in use or not
Definition at line 960 of file class.assQuestion.php.
References $query, $result, and $row.
{
if ($question_id < 1) $question_id = $this->id;
$query = sprintf("SELECT COUNT(question_id) AS question_count FROM qpl_questions WHERE original_id = %s",
$this->ilias->db->quote($question_id . "")
);
$result = $this->ilias->db->query($query);
$row = $result->fetchRow(DB_FETCHMODE_OBJECT);
return $row->question_count;
}
| ASS_Question::keyInArray | ( | $ | searchkey, | |
| $ | array | |||
| ) |
returns TRUE if the key occurs in an array
returns TRUE if the key occurs in an array
| string | $arraykey A key to an element in array | |
| array | $array An array to be searched public |
Definition at line 416 of file class.assQuestion.php.
{
if ($searchKey)
{
foreach ($array as $key => $value)
{
if (strcmp($key, $searchkey)==0)
{
return true;
}
}
}
return false;
}
| ASS_Question::loadFromDb | ( | $ | question_id | ) |
Loads the question from the database.
Loads the question from the database
| integer | $question_id A unique key which defines the question in the database public |
Reimplemented in ASS_ClozeTest, ASS_ImagemapQuestion, ASS_JavaApplet, ASS_MatchingQuestion, ASS_MultipleChoice, ASS_OrderingQuestion, and ASS_TextQuestion.
Definition at line 1307 of file class.assQuestion.php.
References $query, $result, and $row.
{
$query = sprintf("SELECT * FROM qpl_suggested_solutions WHERE question_fi = %s",
$this->ilias->db->quote($this->getId() . "")
);
$result = $this->ilias->db->query($query);
$this->suggested_solutions = array();
if ($result->numRows())
{
while ($row = $result->fetchRow(DB_FETCHMODE_ASSOC))
{
$this->suggested_solutions[$row["subquestion_index"]] = array(
"internal_link" => $row["internal_link"],
"import_id" => $row["import_id"]
);
}
}
}
| ASS_Question::pcArrayShuffle | ( | $ | array | ) |
Shuffles the values of a given array.
Shuffles the values of a given array
| array | $array An array which should be shuffled public |
Definition at line 1005 of file class.assQuestion.php.
Referenced by ASS_OrderingQuestion::to_xml(), ASS_MultipleChoice::to_xml(), ASS_MatchingQuestion::to_xml(), and ASS_ClozeTest::to_xml().
{
mt_srand((double)microtime()*1000000);
$i = count($array);
if ($i > 0)
{
while(--$i)
{
$j = mt_rand(0, $i);
if ($i != $j)
{
// swap elements
$tmp = $array[$j];
$array[$j] = $array[$i];
$array[$i] = $tmp;
}
}
}
return $array;
}
Here is the caller graph for this function:| ASS_Question::questionTitleExists | ( | $ | title | ) |
Returns TRUE if the question title exists in the database.
Returns TRUE if the question title exists in the database
| string | $title The title of the question |
Definition at line 283 of file class.assQuestion.php.
| ASS_Question::saveToDb | ( | $ | original_id = "" |
) |
Saves the question to the database.
Saves the question to the database
| integer | $original_id public |
Reimplemented in ASS_ClozeTest, ASS_ImagemapQuestion, ASS_JavaApplet, ASS_MatchingQuestion, ASS_MultipleChoice, ASS_OrderingQuestion, and ASS_TextQuestion.
Definition at line 1334 of file class.assQuestion.php.
References $query, $result, ilInternalLink::_deleteAllLinksOfSource(), ilInternalLink::_saveLink(), and getId().
{
require_once "./content/classes/Pages/class.ilInternalLink.php";
$query = sprintf("DELETE FROM qpl_suggested_solutions WHERE question_fi = %s",
$this->ilias->db->quote($this->getId() . "")
);
$result = $this->ilias->db->query($query);
ilInternalLink::_deleteAllLinksOfSource("qst", $this->getId());
foreach ($this->suggested_solutions as $index => $solution)
{
$query = sprintf("INSERT INTO qpl_suggested_solutions (suggested_solution_id, question_fi, internal_link, import_id, subquestion_index, TIMESTAMP) VALUES (NULL, %s, %s, %s, %s, NULL)",
$this->ilias->db->quote($this->getId() . ""),
$this->ilias->db->quote($solution["internal_link"] . ""),
$this->ilias->db->quote($solution["import_id"] . ""),
$this->ilias->db->quote($index . "")
);
$this->ilias->db->query($query);
if (preg_match("/il_(\d*?)_(\w+)_(\d+)/", $solution["internal_link"], $matches))
{
ilInternalLink::_saveLink("qst", $this->getId(), $matches[2], $matches[3], $matches[1]);
}
}
}
Here is the call graph for this function:| ASS_Question::saveWorkingData | ( | $ | test_id, | |
| $ | limit_to = LIMIT_NO_LIMIT | |||
| ) |
Saves the learners input of the question to the database.
Saves the learners input of the question to the database
*
| integer | $test_id The database id of the test containing this question public |
Reimplemented in ASS_ClozeTest, ASS_ImagemapQuestion, ASS_JavaApplet, ASS_MatchingQuestion, ASS_MultipleChoice, ASS_OrderingQuestion, and ASS_TextQuestion.
Definition at line 854 of file class.assQuestion.php.
References $ilUser, $query, $result, $test_id, and getId().
{
global $ilDB;
global $ilUser;
$db =& $ilDB->db;
$reached_points = $this->calculateReachedPoints($ilUser->id, $test_id);
$query = sprintf("REPLACE INTO tst_test_result (user_fi, test_fi, question_fi, points) VALUES (%s, %s, %s, %s)",
$db->quote($ilUser->id . ""),
$db->quote($test_id . ""),
$db->quote($this->getId() . ""),
$db->quote($reached_points . "")
);
$result = $db->query($query);
}
Here is the call graph for this function:| ASS_Question::setAuthor | ( | $ | author = "" |
) |
Sets the authors name.
Sets the authors name of the ASS_Question object
| string | $author A string containing the name of the questions author public |
Definition at line 440 of file class.assQuestion.php.
References $author.
Referenced by ASS_TextQuestion::from_xml(), ASS_OrderingQuestion::from_xml(), ASS_MultipleChoice::from_xml(), ASS_MatchingQuestion::from_xml(), ASS_JavaApplet::from_xml(), ASS_ImagemapQuestion::from_xml(), and ASS_ClozeTest::from_xml().
Here is the caller graph for this function:| ASS_Question::setComment | ( | $ | comment = "" |
) |
Sets the comment.
Sets the comment string of the ASS_Question object
| string | $comment A comment string to describe the question public |
Definition at line 350 of file class.assQuestion.php.
References $comment.
Referenced by ASS_TextQuestion::from_xml(), ASS_OrderingQuestion::from_xml(), ASS_MultipleChoice::from_xml(), ASS_MatchingQuestion::from_xml(), ASS_JavaApplet::from_xml(), ASS_ImagemapQuestion::from_xml(), and ASS_ClozeTest::from_xml().
{
$this->comment = $comment;
}
Here is the caller graph for this function:| ASS_Question::setEstimatedWorkingTime | ( | $ | hour = 0, |
|
| $ | min = 0, |
|||
| $ | sec = 0 | |||
| ) |
Sets the estimated working time of a question.
Sets the estimated working time of a question
| integer | $hour Hour | |
| integer | $min Minutes | |
| integer | $sec Seconds public |
Definition at line 402 of file class.assQuestion.php.
Referenced by ASS_Question(), ASS_TextQuestion::from_xml(), ASS_OrderingQuestion::from_xml(), ASS_MultipleChoice::from_xml(), ASS_MatchingQuestion::from_xml(), ASS_JavaApplet::from_xml(), ASS_ImagemapQuestion::from_xml(), ASS_ClozeTest::from_xml(), ASS_TextQuestion::loadFromDb(), ASS_OrderingQuestion::loadFromDb(), ASS_MultipleChoice::loadFromDb(), ASS_MatchingQuestion::loadFromDb(), ASS_JavaApplet::loadFromDb(), ASS_ImagemapQuestion::loadFromDb(), and ASS_ClozeTest::loadFromDb().
{
$this->est_working_time = array("h" => (int)$hour, "m" => (int)$min, "s" => (int)$sec);
}
Here is the caller graph for this function:| ASS_Question::setId | ( | $ | id = -1 |
) |
Sets the id.
Sets the id of the ASS_Question object
| integer | $id A unique integer value public |
Definition at line 322 of file class.assQuestion.php.
References $id.
{
$this->id = $id;
}
| ASS_Question::setObjId | ( | $ | obj_id = 0 |
) |
Set the object id of the container object.
Set the object id of the container object
| integer | $obj_id The object id of the container object public |
Definition at line 616 of file class.assQuestion.php.
References $obj_id.
{
$this->obj_id = $obj_id;
}
| ASS_Question::setOutputType | ( | $ | outputType = OUTPUT_HTML |
) |
Sets the output type.
Sets the output type
| integer | $outputType The output type of the question public |
Definition at line 364 of file class.assQuestion.php.
References $outputType.
{
$this->outputType = $outputType;
}
| ASS_Question::setOwner | ( | $ | owner = "" |
) |
Sets the creator/owner.
Sets the creator/owner ID of the ASS_Question object
| integer | $owner A numerical ID to identify the owner/creator public |
Definition at line 458 of file class.assQuestion.php.
References $owner.
{
$this->owner = $owner;
}
| ASS_Question::setPoints | ( | $ | a_points | ) |
Sets the maximum available points for the question.
Sets the maximum available points for the question
| integer | $a_points The points public |
Definition at line 1775 of file class.assQuestion.php.
Referenced by ASS_TextQuestion::from_xml(), and ASS_JavaApplet::from_xml().
{
$this->points = $a_points;
}
Here is the caller graph for this function:| ASS_Question::setShuffle | ( | $ | shuffle = true |
) |
Sets the shuffle flag.
Sets the shuffle flag
| boolean | $shuffle A flag indicating whether the answers are shuffled or not public |
Definition at line 379 of file class.assQuestion.php.
References $shuffle.
Referenced by ASS_OrderingQuestion::from_xml(), ASS_MultipleChoice::from_xml(), ASS_MatchingQuestion::from_xml(), ASS_MultipleChoice::loadFromDb(), and ASS_JavaApplet::loadFromDb().
{
if ($shuffle)
{
$this->shuffle = 1;
}
else
{
$this->shuffle = 0;
}
}
Here is the caller graph for this function:| ASS_Question::setSuggestedSolution | ( | $ | solution_id = "", |
|
| $ | subquestion_index = 0, |
|||
| $ | is_import = false | |||
| ) |
Sets a suggested solution for the question.
Sets a suggested solution for the question. If there is more than one subquestion (i.e. close questions) may enter a subquestion index.
| string | $solution_id An internal link pointing to the suggested solution | |
| integer | $subquestion_index The index of a subquestion (i.e. a close test gap). Usually 0 | |
| boolean | $is_import A boolean indication that the internal link was imported from another ILIAS installation public |
Definition at line 1433 of file class.assQuestion.php.
References _resolveInternalLink().
Referenced by ASS_TextQuestion::from_xml(), ASS_OrderingQuestion::from_xml(), ASS_MultipleChoice::from_xml(), ASS_MatchingQuestion::from_xml(), ASS_JavaApplet::from_xml(), ASS_ImagemapQuestion::from_xml(), and ASS_ClozeTest::from_xml().
{
if (strcmp($solution_id, "") != 0)
{
$import_id = "";
if ($is_import)
{
$import_id = $solution_id;
$solution_id = $this->_resolveInternalLink($import_id);
}
$this->suggested_solutions[$subquestion_index] = array(
"internal_link" => $solution_id,
"import_id" => $import_id
);
}
}
Here is the call graph for this function:
Here is the caller graph for this function:| ASS_Question::setTestId | ( | $ | id = -1 |
) |
Sets the test id.
Sets the test id of the ASS_Question object
| integer | $id A unique integer value public |
Definition at line 336 of file class.assQuestion.php.
References $id.
{
$this->test_id = $id;
}
| ASS_Question::setTitle | ( | $ | title = "" |
) |
Sets the title string.
Sets the title string of the ASS_Question object
| string | $title A title string to describe the question public |
Definition at line 308 of file class.assQuestion.php.
References $title.
Referenced by ASS_TextQuestion::from_xml(), ASS_OrderingQuestion::from_xml(), ASS_MultipleChoice::from_xml(), ASS_MatchingQuestion::from_xml(), ASS_JavaApplet::from_xml(), ASS_ImagemapQuestion::from_xml(), and ASS_ClozeTest::from_xml().
{
$this->title = $title;
}
Here is the caller graph for this function:| ASS_Question::syncWithOriginal | ( | ) |
Reimplemented in ASS_ClozeTest, ASS_ImagemapQuestion, ASS_JavaApplet, ASS_MatchingQuestion, ASS_MultipleChoice, ASS_OrderingQuestion, and ASS_TextQuestion.
Definition at line 1607 of file class.assQuestion.php.
References $query, $result, ilInternalLink::_deleteAllLinksOfSource(), and ilInternalLink::_saveLink().
{
require_once "./content/classes/Pages/class.ilInternalLink.php";
$query = sprintf("DELETE FROM qpl_suggested_solutions WHERE question_fi = %s",
$this->ilias->db->quote($this->original_id . "")
);
$result = $this->ilias->db->query($query);
ilInternalLink::_deleteAllLinksOfSource("qst", $this->original_id);
foreach ($this->suggested_solutions as $index => $solution)
{
$query = sprintf("INSERT INTO qpl_suggested_solutions (suggested_solution_id, question_fi, internal_link, import_id, subquestion_index, TIMESTAMP) VALUES (NULL, %s, %s, %s, %s, NULL)",
$this->ilias->db->quote($this->original_id . ""),
$this->ilias->db->quote($solution["internal_link"] . ""),
$this->ilias->db->quote($solution["import_id"] . ""),
$this->ilias->db->quote($index . "")
);
$this->ilias->db->query($query);
if (preg_match("/il_(\d*?)_(\w+)_(\d+)/", $solution["internal_link"], $matches))
{
ilInternalLink::_saveLink("qst", $this->original_id, $matches[2], $matches[3], $matches[1]);
}
}
}
Here is the call graph for this function:| ASS_Question::to_xml | ( | ) |
Returns a QTI xml representation of the question.
Returns a QTI xml representation of the question and sets the internal domxml variable with the DOM XML representation of the QTI xml representation
Definition at line 256 of file class.assQuestion.php.
{
// to be implemented in the successor classes of ASS_Question
}
| ASS_Question::$author |
Definition at line 97 of file class.assQuestion.php.
Referenced by ASS_ClozeTest::ASS_ClozeTest(), ASS_ImagemapQuestion::ASS_ImagemapQuestion(), ASS_JavaApplet::ASS_JavaApplet(), ASS_MatchingQuestion::ASS_MatchingQuestion(), ASS_MultipleChoice::ASS_MultipleChoice(), ASS_OrderingQuestion::ASS_OrderingQuestion(), ASS_Question(), ASS_TextQuestion::ASS_TextQuestion(), ASS_TextQuestion::duplicate(), ASS_OrderingQuestion::duplicate(), ASS_MultipleChoice::duplicate(), ASS_MatchingQuestion::duplicate(), ASS_JavaApplet::duplicate(), ASS_ImagemapQuestion::duplicate(), ASS_ClozeTest::duplicate(), and setAuthor().
| ASS_Question::$comment |
Definition at line 77 of file class.assQuestion.php.
Referenced by ASS_ClozeTest::ASS_ClozeTest(), ASS_ImagemapQuestion::ASS_ImagemapQuestion(), ASS_JavaApplet::ASS_JavaApplet(), ASS_MatchingQuestion::ASS_MatchingQuestion(), ASS_MultipleChoice::ASS_MultipleChoice(), ASS_OrderingQuestion::ASS_OrderingQuestion(), ASS_Question(), ASS_TextQuestion::ASS_TextQuestion(), ASS_TextQuestion::from_xml(), ASS_OrderingQuestion::from_xml(), ASS_MultipleChoice::from_xml(), ASS_MatchingQuestion::from_xml(), ASS_JavaApplet::from_xml(), ASS_ImagemapQuestion::from_xml(), ASS_ClozeTest::from_xml(), and setComment().
| ASS_Question::$domxml |
Definition at line 180 of file class.assQuestion.php.
| ASS_Question::$est_working_time |
Definition at line 117 of file class.assQuestion.php.
| ASS_Question::$id |
Definition at line 59 of file class.assQuestion.php.
Referenced by setId(), and setTestId().
| ASS_Question::$ilias |
Definition at line 153 of file class.assQuestion.php.
Referenced by ASS_Question(), ASS_TextQuestion::loadFromDb(), ASS_OrderingQuestion::loadFromDb(), ASS_MultipleChoice::loadFromDb(), ASS_MatchingQuestion::loadFromDb(), ASS_JavaApplet::loadFromDb(), ASS_ImagemapQuestion::loadFromDb(), ASS_ClozeTest::loadFromDb(), ASS_TextQuestion::saveToDb(), ASS_OrderingQuestion::saveToDb(), ASS_MultipleChoice::saveToDb(), ASS_MatchingQuestion::saveToDb(), ASS_JavaApplet::saveToDb(), ASS_ImagemapQuestion::saveToDb(), ASS_ClozeTest::saveToDb(), ASS_TextQuestion::syncWithOriginal(), ASS_OrderingQuestion::syncWithOriginal(), ASS_MultipleChoice::syncWithOriginal(), ASS_MatchingQuestion::syncWithOriginal(), ASS_JavaApplet::syncWithOriginal(), ASS_ImagemapQuestion::syncWithOriginal(), and ASS_ClozeTest::syncWithOriginal().
| ASS_Question::$lng |
Definition at line 171 of file class.assQuestion.php.
Referenced by ASS_Question(), and ASS_ClozeTest::update_all_gap_params().
| ASS_Question::$obj_id |
Definition at line 144 of file class.assQuestion.php.
Referenced by delete(), and setObjId().
| ASS_Question::$outputType |
Definition at line 189 of file class.assQuestion.php.
Referenced by setOutputType().
| ASS_Question::$owner |
Definition at line 87 of file class.assQuestion.php.
Referenced by ASS_ClozeTest::ASS_ClozeTest(), ASS_ImagemapQuestion::ASS_ImagemapQuestion(), ASS_JavaApplet::ASS_JavaApplet(), ASS_MatchingQuestion::ASS_MatchingQuestion(), ASS_MultipleChoice::ASS_MultipleChoice(), ASS_OrderingQuestion::ASS_OrderingQuestion(), ASS_Question(), ASS_TextQuestion::ASS_TextQuestion(), ASS_TextQuestion::duplicate(), ASS_OrderingQuestion::duplicate(), ASS_MultipleChoice::duplicate(), ASS_MatchingQuestion::duplicate(), ASS_JavaApplet::duplicate(), ASS_ImagemapQuestion::duplicate(), ASS_ClozeTest::duplicate(), and setOwner().
| ASS_Question::$points |
Definition at line 108 of file class.assQuestion.php.
Referenced by _getMaximumPoints(), _getReachedPoints(), ASS_TextQuestion::_setReachedPoints(), ASS_OrderingQuestion::add_answer(), ASS_MultipleChoice::add_answer(), ASS_ImagemapQuestion::add_answer(), ASS_MatchingQuestion::add_matchingpair(), ASS_OrderingQuestion::addAnswer(), ASS_MultipleChoice::addAnswer(), ASS_ImagemapQuestion::addAnswer(), ASS_ClozeTest::addAnswer(), ASS_MatchingQuestion::addMatchingPair(), ASS_TextQuestion::calculateReachedPoints(), ASS_OrderingQuestion::calculateReachedPoints(), ASS_MultipleChoice::calculateReachedPoints(), ASS_MatchingQuestion::calculateReachedPoints(), ASS_JavaApplet::calculateReachedPoints(), ASS_ImagemapQuestion::calculateReachedPoints(), ASS_ClozeTest::calculateReachedPoints(), ASS_OrderingQuestion::getMaximumPoints(), ASS_MultipleChoice::getMaximumPoints(), ASS_MatchingQuestion::getMaximumPoints(), ASS_ImagemapQuestion::getMaximumPoints(), ASS_ClozeTest::getMaximumPoints(), ASS_MatchingQuestion::getReachedInformation(), getReachedPoints(), ASS_ClozeTest::set_gap_points(), ASS_ClozeTest::set_single_answer_points(), and ASS_TextQuestion::setReachedPoints().
| ASS_Question::$shuffle |
Definition at line 126 of file class.assQuestion.php.
Referenced by ASS_ClozeTest::addAnswer(), ASS_ClozeTest::createCloseTextFromArray(), ASS_OrderingQuestion::from_xml(), ASS_MultipleChoice::from_xml(), ASS_MatchingQuestion::from_xml(), ASS_JavaApplet::from_xml(), ASS_ImagemapQuestion::from_xml(), ASS_ClozeTest::from_xml(), ASS_ClozeTest::saveToDb(), ASS_ClozeTest::set_cloze_text(), ASS_ClozeTest::set_gap_shuffle(), and setShuffle().
| ASS_Question::$suggested_solutions |
Definition at line 191 of file class.assQuestion.php.
| ASS_Question::$test_id |
Definition at line 135 of file class.assQuestion.php.
Referenced by _getReachedPoints(), ASS_TextQuestion::_setReachedPoints(), ASS_TextQuestion::calculateReachedPoints(), ASS_OrderingQuestion::calculateReachedPoints(), ASS_MultipleChoice::calculateReachedPoints(), ASS_MatchingQuestion::calculateReachedPoints(), ASS_JavaApplet::calculateReachedPoints(), ASS_ImagemapQuestion::calculateReachedPoints(), ASS_ClozeTest::calculateReachedPoints(), ASS_OrderingQuestion::createRandomSolution(), ASS_MultipleChoice::createRandomSolution(), ASS_MatchingQuestion::createRandomSolution(), ASS_TextQuestion::getReachedInformation(), ASS_OrderingQuestion::getReachedInformation(), ASS_MultipleChoice::getReachedInformation(), ASS_MatchingQuestion::getReachedInformation(), ASS_JavaApplet::getReachedInformation(), ASS_ImagemapQuestion::getReachedInformation(), ASS_ClozeTest::getReachedInformation(), getReachedPoints(), getSolutionCommentCountSystem(), getSolutionCommentMCScoring(), getSolutionValues(), insertIntoTest(), ASS_TextQuestion::saveWorkingData(), saveWorkingData(), ASS_OrderingQuestion::saveWorkingData(), ASS_MultipleChoice::saveWorkingData(), ASS_MatchingQuestion::saveWorkingData(), ASS_JavaApplet::saveWorkingData(), ASS_ImagemapQuestion::saveWorkingData(), ASS_ClozeTest::saveWorkingData(), ASS_TextQuestion::setReachedPoints(), and ASS_MultipleChoice::wasAnsweredByUser().
| ASS_Question::$title |
Definition at line 68 of file class.assQuestion.php.
Referenced by ASS_ClozeTest::ASS_ClozeTest(), ASS_ImagemapQuestion::ASS_ImagemapQuestion(), ASS_JavaApplet::ASS_JavaApplet(), ASS_MatchingQuestion::ASS_MatchingQuestion(), ASS_MultipleChoice::ASS_MultipleChoice(), ASS_OrderingQuestion::ASS_OrderingQuestion(), ASS_Question(), ASS_TextQuestion::ASS_TextQuestion(), ASS_TextQuestion::duplicate(), ASS_OrderingQuestion::duplicate(), ASS_MultipleChoice::duplicate(), ASS_MatchingQuestion::duplicate(), ASS_JavaApplet::duplicate(), ASS_ImagemapQuestion::duplicate(), ASS_ClozeTest::duplicate(), getSuggestedSolutionTitle(), questionTitleExists(), and setTitle().
| ASS_Question::$tpl |
Definition at line 162 of file class.assQuestion.php.
Referenced by ASS_Question().
1.7.1