Make WordPress Core

Ticket #53876: 53876.patch

File 53876.patch, 1.5 KB (added by aadilali, 3 years ago)
  • src/wp-includes/deprecated.php

     
    20242024}
    20252025
    20262026/**
    2027  * Performs esc_url() for database or redirect usage.
    2028  *
    2029  * @since 2.3.1
    2030  * @deprecated 2.8.0 Use esc_url_raw()
    2031  * @see esc_url_raw()
    2032  *
    2033  * @param string $url The URL to be cleaned.
    2034  * @param array $protocols An array of acceptable protocols.
    2035  * @return string The cleaned URL.
    2036  */
    2037 function sanitize_url( $url, $protocols = null ) {
    2038         _deprecated_function( __FUNCTION__, '2.8.0', 'esc_url_raw()' );
    2039         return esc_url_raw( $url, $protocols );
    2040 }
    2041 
    2042 /**
    20432027 * Checks and cleans a URL.
    20442028 *
    20452029 * A number of characters are removed from the URL. If the URL is for displaying
  • src/wp-includes/formatting.php

     
    55155515}
    55165516
    55175517/**
     5518 * Performs esc_url() for database or redirect usage.
     5519 *
     5520 * @since 2.3.1
     5521 *
     5522 * @param string $url The URL to be cleaned.
     5523 * @param array $protocols An array of acceptable protocols.
     5524 * @return string The cleaned URL.
     5525 */
     5526function sanitize_url( $url, $protocols = null ) {
     5527        return esc_url_raw( $url, $protocols );
     5528       
     5529}
     5530
     5531/**
    55185532 * Adds slashes to a string or recursively adds slashes to strings within an array.
    55195533 *
    55205534 * This should be used when preparing data for core API that expects slashed data.