Changeset 51675 for trunk/src/wp-includes/kses.php
- Timestamp:
- 08/26/2021 07:27:59 PM (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/kses.php
r51550 r51675 847 847 * @param string|array $context The context for which to retrieve tags. Allowed values are 'post', 848 848 * 'strip', 'data', 'entities', or the name of a field filter such as 849 * 'pre_user_description' .849 * 'pre_user_description', or an array of allowed HTML elements and attributes. 850 850 * @return array Array of allowed HTML tags and their allowed attributes. 851 851 */ … … 854 854 855 855 if ( is_array( $context ) ) { 856 // When `$context` is an array it's actually an array of allowed HTML elements and attributes. 857 $html = $context; 858 $context = 'explicit'; 859 856 860 /** 857 861 * Filters the HTML tags that are allowed for a given context. … … 859 863 * @since 3.5.0 860 864 * 861 * @param array[] |string $context Context to judge allowed tags by.862 * @param string $context_typeContext name.865 * @param array[] $html Allowed HTML tags. 866 * @param string $context Context name. 863 867 */ 864 return apply_filters( 'wp_kses_allowed_html', $ context, 'explicit');868 return apply_filters( 'wp_kses_allowed_html', $html, $context ); 865 869 } 866 870
Note: See TracChangeset
for help on using the changeset viewer.