wp_kses_allowed_html хук-фильтр . WP 3.5.0
Filters the HTML that is allowed for a given context.
Использование
add_filter( 'wp_kses_allowed_html', 'filter_function_name_724', 10, 2 ); function filter_function_name_724( $context, $context_type ){ // filter... return $context; }
- $context(массив[]/строка)
- Context to judge allowed tags by.
- $context_type(строка)
- Context name.
Список изменений
С версии 3.5.0 | Введена. |
Где вызывается хук
wp_kses_allowed_html
wp-includes/kses.php 858
return apply_filters( 'wp_kses_allowed_html', $context, 'explicit' );
wp-includes/kses.php 864
$tags = apply_filters( 'wp_kses_allowed_html', $allowedposttags, $context );
wp-includes/kses.php 881
$tags = apply_filters( 'wp_kses_allowed_html', $tags, $context );
wp-includes/kses.php 891
return apply_filters( 'wp_kses_allowed_html', $tags, $context );
wp-includes/kses.php 895
return apply_filters( 'wp_kses_allowed_html', array(), $context );
wp-includes/kses.php 899
return apply_filters( 'wp_kses_allowed_html', $allowedentitynames, $context );
wp-includes/kses.php 904
return apply_filters( 'wp_kses_allowed_html', $allowedtags, $context );
Где используется хук в ядре WordPress
wp-includes/class-wp-customize-widgets.php 1626
add_filter( 'wp_kses_allowed_html', array( $this, 'filter_wp_kses_allowed_data_attributes' ) );