wp_filter_post_kses( string $data )
Sanitizes content for allowed HTML tags for post content.
Description Description
Post content refers to the page contents of the ‘post’ type and not $_POST
data from forms.
This function expects slashed data.
Parameters Parameters
- $data
-
(string) (Required) Post content to filter, expected to be escaped with slashes.
Return Return
(string) Filtered post content with allowed HTML tags and attributes intact.
Source Source
File: wp-includes/kses.php
function wp_filter_post_kses( $data ) { return addslashes( wp_kses( stripslashes( $data ), 'post' ) ); }
Expand full source code Collapse full source code View on Trac
Changelog Changelog
Version | Description |
---|---|
2.0.0 | Introduced. |
User Contributed Notes User Contributed Notes
You must log in before being able to contribute a note or feedback.
The second argument passes to kses() does not match with its documentation :
http://wpsocket.com/wpref/function/wp_kses/