wp_kses_bad_protocol_once


wp_kses_bad_protocol_once ( $string, $allowed_protocols, $count = 1 )

Parameters:
  • (string) $string Content to check for bad protocols.
  • (string[]) $allowed_protocols Array of allowed URL protocols.
Returns:
  • (string) Sanitized content.
Defined at:

Description

Sanitizes content from bad protocols and other characters.

This function searches for URL protocols at the beginning of the string, while handling whitespace and HTML entities.

Related Functions

wp_kses_bad_protocol_once2, wp_kses_bad_protocol, wp_kses_post_deep, wp_allowed_protocols, wp_kses_attr_parse

Top Google Results

User discussions

wpseek mobile