On this page
wp_kses_data( string $data ): string
Sanitize content with allowed HTML KSES rules.
Description
This function expects unslashed data.
Parameters
$datastring Required-
Content to filter, expected to not be escaped.
Return
string Filtered content.
Source
File: wp-includes/kses.php. View all references
function wp_kses_data( $data ) {
return wp_kses( $data, current_filter() );
}
Related
Uses
| Uses | Description |
|---|---|
| wp_kses() wp-includes/kses.php | Filters text content and strips out disallowed HTML. |
| current_filter() wp-includes/plugin.php | Retrieves the name of the current filter hook. |
Used By
| Used By | Description |
|---|---|
| sanitize_option() wp-includes/formatting.php | Sanitizes various option values based on the nature of the option. |
Changelog
| Version | Description |
|---|---|
| 2.9.0 | Introduced. |
© 2003–2022 WordPress Foundation
Licensed under the GNU GPLv2+ License.
https://developer.wordpress.org/reference/functions/wp_kses_data