function html_title_preprocess_search_result in HTML Title 8
Same name and namespace in other branches
- 6 html_title.module \html_title_preprocess_search_result()
- 7 html_title.module \html_title_preprocess_search_result()
Implements hook_preprocess_search_result().
File
- ./
html_title.module, line 55 - HTML Title module to enable limited HTML tags in title.
Code
function html_title_preprocess_search_result(&$variables) {
if (isset($variables['result']['node']) && $variables['result']['node'] instanceof NodeInterface) {
$variables['title'] = \Drupal::service('html_title.filter')
->decodeToMarkup($variables['title']);
}
}