You are here

function messaging_text_filter in Messaging 6.4

Apply filter to message text

1 call to messaging_text_filter()
messaging_text_render in includes/text.inc
Composes message from different parts, recursively and applies filter

File

includes/text.inc, line 60
Drupal Messaging Framework - Text filtering functions

Code

function messaging_text_filter($text, $filter) {
  if (!$filter) {

    // Not filtering for this method
    return $text;
  }
  elseif ($function = messaging_text_filter_info($filter, 'filter callback')) {
    return $function($text);
  }
  else {

    // Filter not valid or not available anymore. Apply plaintext filter.
    return messaging_text_check_plain($text);
  }
}