pre_get_shortlink
最后更新于:2021-11-27 18:51:35
apply_filters( ‘pre_get_shortlink’, false|string $return, int $id, string $context, bool $allow_slugs )
Filters whether to preempt generating a shortlink for the given post.
参数
- $return
-
(false|string)
Short-circuit return value. Either false or a URL string. - $id
-
(int)
Post ID, or 0 for the current post. - $context
-
(string)
The context for the link. One of ‘post’ or ‘query’, - $allow_slugs
-
(bool)
Whether to allow post slugs in the shortlink.
源文件
文件: gc-includes/link-template.php