function qcollection_form in Quiz 6.6
Implementation of hook_form().
File
- includes/
qcollection/ qcollection.module, line 197 - The main file for qcollection.
Code
function qcollection_form(&$node) {
$type = node_get_types('type', $node);
$form = array();
$form['title'] = array(
'#type' => 'textfield',
'#title' => check_plain($type->title_label),
'#default_value' => $node->title,
'#description' => t('The name of the @item_collection.', array(
'@item_collection' => QCOLLECTION_NAME,
)),
'#required' => TRUE,
);
$form['body_field']['body'] = array(
'#type' => 'textarea',
'#title' => check_plain($type->body_label),
'#default_value' => $node->body,
'#description' => t('Notes on the contents and origin of the @qcollection entails', array(
'@qcollection' => QCOLLECTION_NAME,
)),
'#required' => FALSE,
);
$form['body_field']['format'] = filter_form($node->format);
return $form;
}