WordPress at a glance
function is not described

wp_kses_named_entities() WP 3.0.0

Callback for wp_kses_normalize_entities() regular expression.

This function only accepts valid named entity references, which are finite, case-sensitive, and highly scrutinized by HTML and XML validators.

  • Global. Array. $allowedentitynames

No Hooks.


String. Correctly encoded entity


wp_kses_named_entities( $matches );
$matches(array) (required)
preg_replace_callback() matches array

Code of wp kses named entities: wp-includes/kses.php VER 5.0.3

function wp_kses_named_entities($matches) {
	global $allowedentitynames;

	if ( empty($matches[1]) )
		return '';

	$i = $matches[1];
	return ( ! in_array( $i, $allowedentitynames ) ) ? "&amp;$i;" : "&$i;";