You are here

function html_title_preprocess_search_result in HTML Title 6

Same name and namespace in other branches
  1. 8 html_title.module \html_title_preprocess_search_result()
  2. 7 html_title.module \html_title_preprocess_search_result()

Implementation of hook_preprocess_search_result()

1 string reference to 'html_title_preprocess_search_result'
html_title_theme_registry_alter in ./html_title.module
Implementation of hook_theme_registry_alter()

File

./html_title.module, line 72
This module enables limited HTML to be used in node titles. It strips title markup from RSS feeds to eliminate unsightly markup in feed readers.

Code

function html_title_preprocess_search_result(&$vars) {
  if (isset($vars['result']['title'])) {
    $elements = variable_get('html_title_allowed_elements', array(
      'em',
      'sub',
      'sup',
    ));
    $vars['title'] = filter_xss($vars['result']['title'], $elements);
  }
}