function search_facetapi_form_facetapi_realm_settings_form_alter in Faceted Navigation for Search 7
Implements hook_form_alter().
File
- ./
search_facetapi.module, line 38 - Integrates the core Search module with the Facet API project.
Code
function search_facetapi_form_facetapi_realm_settings_form_alter(&$form, &$form_state) {
$adapter = $form['#facetapi']['adapter'];
if ('search' == $adapter
->getId()) {
$active = variable_get('search_active_modules', array(
'node',
'user',
));
if (empty($active['search_facetapi'])) {
$message = t('<em>Faceted Navigation for Search</em> is not set as an active search module in the <a href="@search-settings-url">Search Settings</a> form and is the search page the facets are displayed on.', array(
'@search-settings-url' => url('admin/config/search/settings'),
));
drupal_set_message($message, 'warning');
}
}
}