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 |
|---|---|
| 1037 | /** |
| 1038 | * Filter the search feed link. |
| 1039 | * |
| 1040 | * @since 2.5.0 |
| 1041 | * |
| 1042 | * @param string $link Search feed link. |
| 1043 | * @param string $feed Feed type. |
| 1044 | * @param string $type The search type. One of 'posts' or 'comments'. |
| 1045 | */ |
| 1046 | $link = apply_filters( 'search_feed_link', $link, $feed, 'posts' ); |
| 1047 | |
| 1048 | return $link; |
| 1049 | } |
| 1050 | |
| 1051 | /** |
| 1052 | * Retrieve the permalink for the comments feed of the search results. |
| 1053 | * |
| 1054 | * @since 2.5.0 |
| 1055 | * |
| Line | Code |
| 1067 | |
| 1068 | $permastruct = $wp_rewrite->get_search_permastruct(); |
| 1069 | |
| 1070 | if ( empty($permastruct) ) |
| 1071 | $link = add_query_arg('feed', 'comments-' . $feed, $link); |
| 1072 | else |
| 1073 | $link = add_query_arg('withcomments', 1, $link); |
| 1074 | |
| 1075 | /** This filter is documented in wp-includes/link-template.php */ |
| 1076 | $link = apply_filters('search_feed_link', $link, $feed, 'comments'); |
| 1077 | |
| 1078 | return $link; |
| 1079 | } |
| 1080 | |
| 1081 | /** |
| 1082 | * Retrieve the permalink for a post type archive. |
| 1083 | * |
| 1084 | * @since 3.1.0 |
| 1085 | * |