rest_namespace_index
apply_filters( ‘rest_namespace_index’, WP_REST_Response $response, WP_REST_Request $request )
过滤器::过滤命名空间索引数据。
Filter Hook: Filters the namespace index data.
说明(Description)
这通常只是命名空间的路由数据,但是您可以在这里添加任何想要的数据。
参数(Parameters)
参数 | 类型 | 说明 |
---|---|---|
$response | (WP_REST_Response) | 响应数据。 |
$request | (WP_REST_Request) | 请求数据。命名空间作为“namespace”参数传递。 |
源码(Source)
更新版本 | 源码位置 | 使用 | 被使用 |
---|---|---|---|
4.4.0 | wp-includes/rest-api/class-wp-rest-server.php:1172 | 1 | 0 |
rest_namespace_index 为WP2原创文章,链接:https://www.wp2.cn/hook/rest_namespace_index/