truefalse.module in Quiz 6.6
Same filename and directory in other branches
TrueFalse question type for quiz module
Allows the creation of true or false questions, which associate one term with another
File
question_types/truefalse/truefalse.moduleView source
<?php
/**
* @file
* TrueFalse question type for quiz module
*
* Allows the creation of true or false questions, which associate one term
* with another
*/
/**
* Implementation of hook_help().
*/
function truefalse_help($path, $args) {
switch ($path) {
case 'admin/modules#description':
return t('TrueFalse question type for quiz module.');
case 'node/add#truefalse':
case 'admin/help#truefalse':
return t('A question type for the quiz module: allows you to create truefalse type questions, which connect terms with one another.');
default:
break;
}
}
/**
* Implementation of hook_menu().
*/
/*
function truefalse_menu() {
$items = array();
$items['admin/quiz/truefalse'] = array(
'title' => t('TrueFalse configuration'),
'description' => t('Configure TrueFalse questions for users.'),
'page callback' => 'drupal_get_form',
'page arguments' => array('truefalse_admin_settings_form'),
'access arguments' => array(QUIZ_PERM_ADMIN_CONFIG),
'type' => MENU_NORMAL_ITEM,
);
return $items;
}
*/
/**
* Implementation of hook_quiz_question_info().
*/
function truefalse_quiz_question_info() {
return array(
'true_false' => array(
'name' => 'True/false question',
'description' => 'Quiz questions that allow a user to select true or false (yes/no).',
'question provider' => 'TrueFalseQuestion',
'response provider' => 'TrueFalseResponse',
'module' => 'quiz_question',
),
);
}
/**
* Implementation of hook_autoload_info().
*/
function truefalse_autoload_info() {
return array(
'TrueFalseQuestion' => array(
'file' => 'truefalse.classes.inc',
),
'TrueFalseResponse' => array(
'file' => 'truefalse.classes.inc',
),
);
}
/**
* Implementation of hook_theme().
*/
function truefalse_theme() {
return array(
'truefalse_report' => array(
'arguments' => array(
'question' => NULL,
'show_points' => NULL,
'show_feedback' => NULL,
),
'file' => 'truefalse.theme.inc',
),
);
}
/*
function truefalse_admin_settings_form() {
$form = array();
return system_settings_form($form);
}
*/
Functions
Name | Description |
---|---|
truefalse_autoload_info | Implementation of hook_autoload_info(). |
truefalse_help | Implementation of hook_help(). |
truefalse_quiz_question_info | Implementation of hook_quiz_question_info(). |
truefalse_theme | Implementation of hook_theme(). |