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



rest_query_var-{$key} › WordPress过滤钩子

Since4.7.0
已弃用n/a
apply_filters( "rest_query_var-{$key}", $value )
参数:
  • (string) $value The query_var value.
    Required: Yes
定义在:
文档:

Filters the query_vars used in get_items() for the constructed query.

The dynamic portion of the hook name, $key, refers to the query_var key.





源码

$query_args[ $key ] = apply_filters( "rest_query_var-{$key}", $value ); // phpcs:ignore WordPress.NamingConventions.ValidHookName.UseUnderscores