Document the default list of allowed protocols in the doc block for wp_allowed_protocols()
and cross-reference in esc_url()
and the kses_allowed_protocols
filter.
Props GunGeekATX. Fixes #32421. git-svn-id: https://develop.svn.wordpress.org/trunk@32797 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
b9b36d1c57
commit
a4765f9e1b
@ -3126,9 +3126,7 @@ function esc_sql( $data ) {
|
||||
*
|
||||
* @param string $url The URL to be cleaned.
|
||||
* @param array $protocols Optional. An array of acceptable protocols.
|
||||
* Defaults to 'http', 'https', 'ftp', 'ftps', 'mailto',
|
||||
* 'news', 'irc', 'gopher', 'nntp', 'feed', 'telnet', 'mms',
|
||||
* 'rtsp', 'svn' if not set.
|
||||
* Defaults to return value of wp_allowed_protocols()
|
||||
* @param string $_context Private. Use esc_url_raw() for database usage.
|
||||
* @return string The cleaned $url after the 'clean_url' filter is applied.
|
||||
*/
|
||||
|
@ -4506,6 +4506,7 @@ function send_frame_options_header() {
|
||||
* @staticvar array $protocols
|
||||
*
|
||||
* @return array Array of allowed protocols.
|
||||
* Defaults to 'http', 'https', 'ftp', 'ftps', 'mailto', 'news', 'irc', 'gopher', 'nntp', 'feed', 'telnet', 'mms', 'rtsp', 'svn', 'tel', 'fax', 'xmpp', 'webcal'
|
||||
*/
|
||||
function wp_allowed_protocols() {
|
||||
static $protocols = array();
|
||||
|
Loading…
Reference in New Issue
Block a user