WP_REST_Controller::sanitize_slug

SummerySummery

Sanitizes the slug value.

Syntax

WP_REST_Controller::sanitize_slug( string $slug )

ParametersParameters

$slug

(string) (Required) Slug value passed in request.

ReturnReturn

(string) Sanitized value for the slug.

SourceSource

File: wp-includes/rest-api/endpoints/class-wp-rest-controller.php


			

ChangelogChangelog

Changelog
Version Description
4.7.0 Introduced.

See alsoSee also

Scroll to Top