1 filter_example.module _filter_example_filter_time_prepare($text, $filter)

Time filter prepare callback.

We'll use [filter-example-time] as a replacement for the time tag. Note that, in a more complicated filter, a closing tag may also be required.

Related topics

File

modules/examples/filter_example/filter_example.module, line 162
Hook implementations for the Filter Example module.

Code

function _filter_example_filter_time_prepare($text, $filter) {
  return preg_replace('!<time ?/>!', '[filter-example-time]', $text);
}