WP_REST_Global_Styles_Controller::_sanitize_global_styles_callback
Sanitize the global styles stylesheet to decode endpoint. For example, wp/v2/global-styles/twentytwentytwo%200.4.0 would be decoded to twentytwentytwo 0.4.0.
Method of the class: WP_REST_Global_Styles_Controller{}
No Hooks.
Returns
String. Sanitized global styles stylesheet.
Usage
$WP_REST_Global_Styles_Controller = new WP_REST_Global_Styles_Controller(); $WP_REST_Global_Styles_Controller->_sanitize_global_styles_callback( $stylesheet );
- $stylesheet(string) (required)
- Global styles stylesheet.
Changelog
| Since 5.9.0 | Introduced. |
WP_REST_Global_Styles_Controller::_sanitize_global_styles_callback() WP REST Global Styles Controller:: sanitize global styles callback code WP 7.0
public function _sanitize_global_styles_callback( $stylesheet ) {
return urldecode( $stylesheet );
}