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.
| Line | Code |
|---|---|
| 1138 | |
| 1139 | debug_fwrite( $log, 'Post contents:' ); |
| 1140 | debug_fwrite( $log, $content . "\n" ); |
| 1141 | |
| 1142 | foreach ( $pung as $link_test ) { |
| 1143 | if ( !in_array( $link_test, $post_links_temp[0] ) ) { // link no longer in post |
| 1144 | $mid = $wpdb->get_col( $wpdb->prepare("SELECT meta_id FROM $wpdb->postmeta WHERE post_id = %d AND meta_key = 'enclosure' AND meta_value LIKE (%s)", $post_ID, $link_test . '%') ); |
| 1145 | do_action( 'delete_postmeta', $mid ); |
| 1146 | $wpdb->query( $wpdb->prepare("DELETE FROM $wpdb->postmeta WHERE post_id IN(%s)", implode( ',', $mid ) ) ); |
| 1147 | do_action( 'deleted_postmeta', $mid ); |
| 1148 | } |
| 1149 | } |
| 1150 | |
| 1151 | foreach ( (array) $post_links_temp[0] as $link_test ) { |
| 1152 | if ( !in_array( $link_test, $pung ) ) { // If we haven't pung it already |
| 1153 | $test = parse_url( $link_test ); |
| 1154 | if ( isset( $test['query'] ) ) |
| 1155 | $post_links[] = $link_test; |
| 1156 | elseif ( $test['path'] != '/' && $test['path'] != '' ) |