mirror of
https://github.com/WordPress/WordPress.git
synced 2024-09-28 23:27:39 +02:00
Pass the $adjacent parameter to the "{$adjacent}_post_link" filter.
props ankit.gade@rtcamp.com, kpdesign. fixes #30440. Built from https://develop.svn.wordpress.org/trunk@31000 git-svn-id: http://core.svn.wordpress.org/trunk@30982 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
8572a07a25
commit
ed7033ec9b
@ -1865,13 +1865,15 @@ function get_adjacent_post_link( $format, $link, $in_same_term = false, $exclude
|
|||||||
* of adjacency, 'next' or 'previous'.
|
* of adjacency, 'next' or 'previous'.
|
||||||
*
|
*
|
||||||
* @since 2.6.0
|
* @since 2.6.0
|
||||||
|
* @since 4.2.0 Added the `$adjacent` parameter.
|
||||||
*
|
*
|
||||||
* @param string $output The adjacent post link.
|
* @param string $output The adjacent post link.
|
||||||
* @param string $format Link anchor format.
|
* @param string $format Link anchor format.
|
||||||
* @param string $link Link permalink format.
|
* @param string $link Link permalink format.
|
||||||
* @param WP_Post $post The adjacent post.
|
* @param WP_Post $post The adjacent post.
|
||||||
|
* @param string $adjacent Whether the post is previous or next.
|
||||||
*/
|
*/
|
||||||
return apply_filters( "{$adjacent}_post_link", $output, $format, $link, $post );
|
return apply_filters( "{$adjacent}_post_link", $output, $format, $link, $post, $adjacent );
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
Reference in New Issue
Block a user