Codex

Function Reference/current filter

Contents

Description

Retrieve the name of the current filter or action.

Usage

<?php current_filter(); ?>

Parameters

None.

Return Values

(string) 
Hook name of the current filter or action.

Examples

See this example from toscho at WordPress Answers

Notes

  • Uses global: (unknown type) $wp_current_filter

Change Log

Since: 2.5

Source File

current_filter() is located in wp-includes/plugin.php.

Related

Filters: has_filter(), add_filter(), apply_filters(), current_filter(), merge_filters(), remove_filter(), remove_all_filters()

See also index of Function Reference and index of Template Tags.