WP_REST_Response::get_links() WordPress Method
The WP_REST_Response::get_links() function is used to retrieve the links associated with a response. The links are represented as an array of WP_REST_Response_Link objects, which contain the href and rel attributes for each link.
WP_REST_Response::get_links() #
Retrieves links for the response.
Return
(array) List of links.
Source
File: wp-includes/rest-api/class-wp-rest-response.php
public function get_links() {
return $this->links;
}
Expand full source codeCollapse full source codeView on TracView on GitHub
Changelog
| Version | Description |
|---|---|
| 4.4.0 | Introduced. |