hook_search_reset
function hook_search_reset
hook_search_reset()
Take action when the search index is going to be rebuilt.
Modules that use hook_update_index() should update their indexing bookkeeping so that it starts from scratch the next time hook_update_index() is called.
Related topics
File
- modules/search/search.api.php, line 73
- Hooks provided by the Search module.
Code
function hook_search_reset() { db_update('search_dataset') ->fields(array('reindex' => REQUEST_TIME)) ->condition('type', 'node') ->execute(); }
© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/modules!search!search.api.php/function/hook_search_reset/7.x