function suggestion_admin_index_form in Autocomplete Search Suggestions 7
Menu callback to index suggestions.
1 string reference to 'suggestion_admin_index_form'
- suggestion_menu in ./
suggestion.module - Implements hook_menu().
File
- ./
suggestion.admin.inc, line 104 - Administration form for suggestion module.
Code
function suggestion_admin_index_form($form) {
$form['feedback'] = array(
'#markup' => '<div id="suggestion-index-feedback">' . (variable_get('suggestion_synced', TRUE) ? t('No indexing required.') : t('Indexing required.')) . '</div>',
'#weight' => 10,
);
$form['flush'] = array(
'#title' => t('Flush all suggestions'),
'#description' => t('Flushes all suggestions including priority and surfer suggestions.'),
'#type' => 'checkbox',
'#default_value' => FALSE,
'#required' => FALSE,
'#weight' => 20,
);
$form['submit'] = array(
'#type' => 'submit',
'#value' => t('Index Suggestions'),
'#weight' => 30,
'#ajax' => array(
'callback' => 'suggestion_index_block_ajax_callback',
'effect' => 'fade',
'method' => 'replace',
'wrapper' => 'suggestion-index-feedback',
),
);
return $form;
}