wp_kses_normalize_entities

Advertisement

Summery Summery

Converts and fixes HTML entities.

Syntax Syntax

wp_kses_normalize_entities( string $string )

Description Description

This function normalizes HTML entities. It will convert AT&T to the correct AT&T, : to :, &#XYZZY; to &#XYZZY; and so on.

Parameters Parameters

$string

(Required) Content to normalize entities.

Return Return

(string) Content with normalized entities.

Source Source

File: wp-includes/kses.php

 * @param string[] $allowed_protocols Array of allowed URL protocols.
 * @return string Sanitized content.
 */
function wp_kses_bad_protocol_once2( $string, $allowed_protocols ) {
	$string2 = wp_kses_decode_entities( $string );
	$string2 = preg_replace( '/\s/', '', $string2 );
	$string2 = wp_kses_no_null( $string2 );
	$string2 = strtolower( $string2 );

	$allowed = false;
	foreach ( (array) $allowed_protocols as $one_protocol ) {

Advertisement

Changelog Changelog

Changelog
Version Description
1.0.0 Introduced.

Advertisement

Leave a Reply