Outil de recherche WordPress pour les développeurs et auteurs de thèmes



wp_filter_post_kses ›

Depuis2.0.0
Dépréciéen/a
wp_filter_post_kses ( $data )
Paramètres:
  • (string) $data Post content to filter, expected to be escaped with slashes.
    Requis: Oui
Retourne:
  • (string) Filtered post content with allowed HTML tags and attributes intact.
Défini(e) dans:
Codex:

Sanitizes content for allowed HTML tags for post content.

Post content refers to the page contents of the 'post' type and not $_POST data from forms.

This function expects slashed data.



Source

function wp_filter_post_kses( $data ) {
	return addslashes( wp_kses( stripslashes( $data ), 'post' ) );
}