equal
deleted
inserted
replaced
43 'args' => array( |
43 'args' => array( |
44 'url' => array( |
44 'url' => array( |
45 'required' => true, |
45 'required' => true, |
46 'description' => __( 'The URL to process.' ), |
46 'description' => __( 'The URL to process.' ), |
47 'validate_callback' => 'wp_http_validate_url', |
47 'validate_callback' => 'wp_http_validate_url', |
48 'sanitize_callback' => 'esc_url_raw', |
48 'sanitize_callback' => 'sanitize_url', |
49 'type' => 'string', |
49 'type' => 'string', |
50 'format' => 'uri', |
50 'format' => 'uri', |
51 ), |
51 ), |
52 ), |
52 ), |
53 'permission_callback' => array( $this, 'permissions_check' ), |
53 'permission_callback' => array( $this, 'permissions_check' ), |
126 /** |
126 /** |
127 * Retrieves the contents of the title tag from the HTML response. |
127 * Retrieves the contents of the title tag from the HTML response. |
128 * |
128 * |
129 * @since 5.9.0 |
129 * @since 5.9.0 |
130 * |
130 * |
131 * @param WP_REST_REQUEST $request Full details about the request. |
131 * @param WP_REST_Request $request Full details about the request. |
132 * @return WP_REST_Response|WP_Error The parsed details as a response object. WP_Error if there are errors. |
132 * @return WP_REST_Response|WP_Error The parsed details as a response object. WP_Error if there are errors. |
133 */ |
133 */ |
134 public function parse_url_details( $request ) { |
134 public function parse_url_details( $request ) { |
135 $url = untrailingslashit( $request['url'] ); |
135 $url = untrailingslashit( $request['url'] ); |
136 |
136 |