Yoast\WP\SEO\Routes
Indexables_Head_Route::get_head()
Gets the head of a page for a given URL.
Метод класса: Indexables_Head_Route{}
Хуков нет.
Возвращает
WP_REST_Response
. The response.
Использование
$Indexables_Head_Route = new Indexables_Head_Route(); $Indexables_Head_Route->get_head( $request );
- $request(WP_REST_Request) (обязательный)
- The request. This request should have a url param set.
Код Indexables_Head_Route::get_head() Indexables Head Route::get head Yoast 24.4
public function get_head( WP_REST_Request $request ) { $url = \esc_url_raw( \utf8_uri_encode( $request['url'] ) ); $data = $this->head_action->for_url( $url ); return new WP_REST_Response( $data, $data->status ); }