Menu Adam R Brown

WP hooks navigation: Home/browseActions indexFilters index

Source View: preview_post_link

To save our bandwidth, we show only a snippet of code around each occurence of the hook. View complete file in SVN (without highlighting).

Understanding Source Code

The best way to understand what a hook does is to look at where it occurs in the source code.

Remember, this hook may occur in more than one file. Moreover, the hook's context may change from version to version.

Source View

Line Code
1218      /**
1219       * Filter the URL used for a post preview.
1220       *
1221       * @since 2.0.5
1222       * @since 4.0.0 Added the `$post` parameter.
1223       *
1224       * @param string  $preview_link URL used for the post preview.
1225       * @param WP_Post $post         Post object.
1226       */
1227      return apply_filters( 'preview_post_link', $preview_link, $post );
1228 }
1229
1230 /**
1231  * Retrieve edit posts link for post.
1232  *
1233  * Can be used within the WordPress loop or outside of it. Can be used with
1234  * pages, posts, attachments, and revisions.
1235  *
1236  * @since 2.3.0