mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-10-05 23:27:04 +00:00
Docs: Clarify the $allowed_protocols default value in various KSES functions.
Add a note that the parameter is optional and defaults to the result of `wp_allowed_protocols()`. This affects: * `wp_kses()` * `filter_block_content()` * `filter_block_kses()` * `filter_block_kses_value()` Includes synchronizing the `$allowed_html` parameter description for consistency. Follow-up to [649], [6630], [18826], [32603], [43016], [46896], [48478]. Props armondal, SergeyBiryukov. Fixes #56580. git-svn-id: https://develop.svn.wordpress.org/trunk@54181 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -706,7 +706,8 @@ if ( ! CUSTOM_TAGS ) {
|
||||
* @param array[]|string $allowed_html An array of allowed HTML elements and attributes,
|
||||
* or a context name such as 'post'. See wp_kses_allowed_html()
|
||||
* for the list of accepted context names.
|
||||
* @param string[] $allowed_protocols Array of allowed URL protocols.
|
||||
* @param string[] $allowed_protocols Optional. Array of allowed URL protocols.
|
||||
* Defaults to the result of wp_allowed_protocols().
|
||||
* @return string Filtered content containing only the allowed HTML.
|
||||
*/
|
||||
function wp_kses( $string, $allowed_html, $allowed_protocols = array() ) {
|
||||
|
||||
Reference in New Issue
Block a user