Skip to content
  • Log In
  • Register
WordPress.org
  • News
  • Download & Extend
    • Get WordPress
    • Themes
    • Patterns
    • Plugins
    • Openverse
    • Mobile
    • Hosting
  • Learn
    • Learn WordPress
    • Documentation
    • Forums
    • WordPress.tv
    • Developers
  • Community
    • Make WordPress
    • WordCamp
    • Meetups
    • Photo Directory
    • Job Board
    • Five for the Future
  • About
    • About WordPress
    • Showcase
    • Gutenberg
    • Enterprise
    • WordPress Swag Store
  • Get WordPress
Get WordPress

Developer Resources

Browse: Home / Reference / wp-includes/rest-api/endpoints/class-wp-rest-search-controller.php

WP_REST_Search_Controller

Class: Core class to search through all WordPress content via the REST API.

Source: wp-includes/rest-api/endpoints/class-wp-rest-search-controller.php:17

Used by 0 functions | Uses 1 function

WP_REST_Search_Controller::__construct()

Method: Constructor.

Source: wp-includes/rest-api/endpoints/class-wp-rest-search-controller.php:65

Used by 1 function | Uses 2 functions

WP_REST_Search_Controller::register_routes()

Method: Registers the routes for the search controller.

Source: wp-includes/rest-api/endpoints/class-wp-rest-search-controller.php:91

Used by 0 functions | Uses 2 functions

WP_REST_Search_Controller::get_items_permission_check()

Method: Checks if a given request has access to search content.

Source: wp-includes/rest-api/endpoints/class-wp-rest-search-controller.php:115

Used by 0 functions | Uses 0 functions

WP_REST_Search_Controller::get_items()

Method: Retrieves a collection of search results.

Source: wp-includes/rest-api/endpoints/class-wp-rest-search-controller.php:127

Used by 0 functions | Uses 9 functions

WP_REST_Search_Controller::prepare_item_for_response()

Method: Prepares a single search result for response.

Source: wp-includes/rest-api/endpoints/class-wp-rest-search-controller.php:195

Used by 1 function | Uses 5 functions

WP_REST_Search_Controller::get_item_schema()

Method: Retrieves the item schema, conforming to JSON Schema.

Source: wp-includes/rest-api/endpoints/class-wp-rest-search-controller.php:231

Used by 0 functions | Uses 1 function

WP_REST_Search_Controller::get_collection_params()

Method: Retrieves the query params for the search results collection.

Source: wp-includes/rest-api/endpoints/class-wp-rest-search-controller.php:300

Used by 1 function | Uses 2 functions

WP_REST_Search_Controller::sanitize_subtypes()

Method: Sanitizes the list of subtypes, to ensure only subtypes of the passed type are included.

Source: wp-includes/rest-api/endpoints/class-wp-rest-search-controller.php:365

Used by 0 functions | Uses 4 functions

WP_REST_Search_Controller::get_search_handler()

Method: Gets the search handler to handle the current request.

Source: wp-includes/rest-api/endpoints/class-wp-rest-search-controller.php:394

Used by 3 functions | Uses 2 functions
  • About
  • News
  • Hosting
  • Donate
  • Swag
  • Documentation
  • Developers
  • Get Involved
  • Learn
  • Showcase
  • Plugins
  • Themes
  • Patterns
  • WordCamp
  • WordPress.TV
  • BuddyPress
  • bbPress
  • WordPress.com
  • Matt
  • Privacy
  • Public Code
WordPress.org
WordPress.org
  • Visit our Facebook page
  • Visit our Twitter account
  • Visit our Instagram account
  • Visit our LinkedIn account
Code is Poetry