filter_format_delete

Versions
7
filter_format_delete($format)

Delete a text format.

Parameters

$format The text format object to be deleted.

Code

modules/filter/filter.module, line 246

<?php
function filter_format_delete($format) {
  db_delete('filter_format')
    ->condition('format', $format->format)
    ->execute();
  db_delete('filter')
    ->condition('format', $format->format)
    ->execute();

  // Allow modules to react on text format deletion.
  $fallback = filter_format_load(filter_fallback_format());
  module_invoke_all('filter_format_delete', $format, $fallback);

  filter_formats_reset();
  cache_clear_all($format->format . ':', 'cache_filter', TRUE);
}
?>
Login or register to post comments
 
 

All source code and documentation on this site is released under the terms of the GNU General Public License, version 2 and later. Drupal is a registered trademark of Dries Buytaert.