* - description: Additional administrative information about the filter's
* behavior, if needed for clarification.
* - settings callback: The name of a function that returns configuration
* form elements for the filter. See hook_filter_FILTER_settings() for
* details.
* - default settings: An associative array containing default settings for
* the filter, to be applied when the filter has not been configured yet.
* - prepare callback: The name of a function that escapes the content before
* the actual filtering happens. See hook_filter_FILTER_prepare() for
* details.
* - process callback: (required) The name the function that performs the
* actual filtering. See hook_filter_FILTER_process() for details.
* - cache (default TRUE): Specifies whether the filtered text can be cached.
* Note that setting this to FALSE makes the entire text format not
* cacheable, which may have an impact on the site's overall performance.
* See filter_format_allowcache() for details.
* - tips callback: The name of a function that returns end-user-facing
* filter usage guidelines for the filter. See hook_filter_FILTER_tips()
* for details.
* - weight: A default weight for the filter in new text formats.
*
* @see filter_example.module
* @see hook_filter_info_alter()
*/
functionhook_filter_info(){
$filters['filter_html']=array(
'title'=>t('Limit allowed HTML tags'),
'type'=>FILTER_TYPE_HTML_RESTRICTOR,
'description'=>t('Allows you to restrict the HTML tags the user can use. It will also remove harmful content such as JavaScript events, JavaScript URLs and CSS styles from those tags that are not removed.'),
returnt('Lines and paragraphs are automatically recognized. The <br /> line break, <p> paragraph and </p> close paragraph tags are inserted automatically. If paragraphs are not recognized simply add a couple blank lines.');
}
else{
returnt('Lines and paragraphs break automatically.');
}
}
/**
* @addtogroup hooks
* @{
*/
/**
* Perform actions when a text format has been disabled.