AnsPress_REST_API::get_answers( WP_REST_Request $request )
Description #
Generate results for the /wp-json/myplugin/v1/foo route.
Parameters #
- $requestWP_REST_Request (Required) Full details about the request.
Source #
File: includes/wp-api.php
public function get_answers( WP_REST_Request $request ) { print_r( $request ); /*if ( empty( $posts ) ) { return new WP_Error( 'awesome_no_author', 'Invalid author', array( 'status' => 404 ) ); }*/ $data = array(); return $data; }
Expand full source code Collapse full source code View on GitHub: includes/wp-api.php:47
Add your comment