function tableofcontents_block_form_filter_admin_configure_alter in Table of Contents 6.3
Implementation of hook_form_FORM_ID_alter().
File
- tableofcontents_block/
tableofcontents_block.module, line 120 - main file for module providing a block
Code
function tableofcontents_block_form_filter_admin_configure_alter(&$form, &$form_state) {
// verify that the table of contents is turned in that filter.
if (isset($form['tableofcontents'])) {
$format = $form['format']['#value'];
// add block specific settings to this filter
$form['tableofcontents']['tableofcontents_block_only_table_' . $format] = array(
'#title' => t('Block-only table of contents'),
'#type' => 'checkbox',
'#default_value' => variable_get('tableofcontents_block_only_table_' . $format, FALSE),
'#description' => 'When checked, all the table of contents are removed from node bodies, only headers are altered. This allows for a block-only table of contents.',
);
}
}