Title: Print all WordPress hooks
Author: Alex Kirk
Published: January 11, 2021

---

# Print all WordPress hooks

January 11, 2021

Ever needed to print out all the hooks in the sequence they are being called (for
example to find a good hook to modify a particular behavior)?

    ```wp-block-code
    add_filter( 'all', function( $tag ) {
    	echo "apply_filters($tag)<br/>";
    } );
    add_action( 'all', function( $tag ) {
    	echo "do_action($tag)<br/>";
    } );
    ```

Is a quick and easy way to do this via a small modification in `wp-settings.php`(
after `plugin.php` is included).

[Web](https://alex.kirk.at/category/web/)

Read this next

[Previous Post](https://alex.kirk.at/2020/12/22/290352/)

### Leave a Reply 󠀁[Cancel reply](https://alex.kirk.at/2021/01/11/print-all-wordpress-hooks/?output_format=md#respond)󠁿

Only people in [my network](https://alex.kirk.at/friends/) can comment.

This site uses Akismet to reduce spam. [Learn how your comment data is processed.](https://akismet.com/privacy/)