WP hooks navigation: Home/browse • Actions index • Filters index
To save our bandwidth, we show only a snippet of code around each occurence of the hook. View complete file in SVN (without highlighting).
The best way to understand what a hook does is to look at where it occurs in the source code.
do_action( "hook_name" )apply_filters( "hook_name", "what_to_filter" ).Remember, this hook may occur in more than one file. Moreover, the hook's context may change from version to version.
This hook occurs 2 times in this file.
| Line | Code |
|---|---|
| 938 | $medium = str_replace( basename( $original ), 'midsize-' . basename( $original ), $original ); |
| 939 | if ( file_exists( $medium ) ) { |
| 940 | /** |
| 941 | * Filter the path of the file to delete. |
| 942 | * |
| 943 | * @since 2.1.0 |
| 944 | * |
| 945 | * @param string $medium Path to the file to delete. |
| 946 | */ |
| 947 | @unlink( apply_filters( 'wp_delete_file', $medium ) ); |
| 948 | } |
| 949 | |
| 950 | if ( empty( $_POST['create-new-attachment'] ) && empty( $_POST['skip-cropping'] ) ) { |
| 951 | /** This filter is documented in wp-admin/custom-header.php */ |
| 952 | @unlink( apply_filters( 'wp_delete_file', $original ) ); |
| 953 | } |
| 954 | |
| 955 | return $this->finished(); |
| 956 | } |
| 957 | |
| 958 | /** |
| 959 | * Display last step of custom header image page. |
| 960 | * |
| 961 | * @since 2.1.0 |