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



attachment_link › WordPress过滤钩子

Since5.6.0
已弃用n/a
apply_filters( 'attachment_link', $link, $post->ID )
参数: (2)
  • (string) $link The attachment's permalink.
    Required: Yes
  • (int) $post_id Attachment ID.
    Required: Yes
定义在:
文档:

Filters the permalink for an attachment.





源码

return apply_filters( 'attachment_link', $link, $post->ID );