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



post_type_link ›

Since3.0.0
已弃用n/a
apply_filters( 'post_type_link', $post_link, $post, $leavename, $sample )
参数: (4)
  • (string) $post_link The post's permalink.
    Required: Yes
  • (WP_Post) $post The post in question.
    Required: Yes
  • (bool) $leavename Whether to keep the post name.
    Required: Yes
  • (bool) $sample Is it a sample permalink.
    Required: Yes
定义在:
文档:

Filters the permalink for a post of a custom post type.





源码

return apply_filters( 'post_type_link', $post_link, $post, $leavename, $sample );