wpseek.com
WordPress开发者和主题制作者的搜索引擎



adjacent_image_link › WordPress Function

Since2.5.0
已弃用n/a
› adjacent_image_link ( $prev = true, $size = 'thumbnail', $text = false )
参数: (3)
  • (bool) $prev Optional. Whether to display the next (false) or previous (true) link. Default true.
    Required: No
    默认: true
  • (string|int[]) $size Optional. Image size. Accepts any registered image size name, or an array of width and height values in pixels (in that order). Default 'thumbnail'.
    Required: No
    默认: 'thumbnail'
  • (bool) $text Optional. Link text. Default false.
    Required: No
    默认: false
定义在:
文档:

Displays next or previous image link that has the same post parent.

Retrieves the current attachment object from the $post global.


源码

function adjacent_image_link( $prev = true, $size = 'thumbnail', $text = false ) {
	echo get_adjacent_image_link( $prev, $size, $text );
}