You are here

function editor_module_implements_alter in Editor 7

Implements hook_module_implements_alter().

File

./editor.module, line 53
Allows rich text fields to be edited using WYSIWYG client-side editors.

Code

function editor_module_implements_alter(&$implementations, $hook) {
  if ($hook == 'element_info_alter') {

    // Move the editor.module implementation of hook_element_info_alter() to the
    // end of the list so that other modules can work with the default
    // filter.module text_format #process function before it is replaced.
    // module_implements() iterates through $implementations with a foreach loop
    // which PHP iterates in the order that the items were added, so to move an
    // item to the end of the array, we remove it and then add it.
    $group = $implementations['editor'];
    unset($implementations['editor']);
    $implementations['editor'] = $group;
  }
}