Make WordPress Core

Changeset 25222


Ignore:
Timestamp:
09/03/2013 08:38:56 AM (11 years ago)
Author:
dd32
Message:

WP_HTTP: Add a filter for the available HTTP Transports to allow plugins to alter the order which HTTP Transports are tried, or to add their own.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/class-http.php

    r25221 r25222  
    215215     */
    216216    public function _get_first_available_transport( $args, $url = null ) {
    217         $request_order = array( 'curl', 'streams', 'fsockopen' );
     217        $request_order = apply_filters( 'http_api_transports', array( 'curl', 'streams', 'fsockopen' ), $args, $url );
    218218
    219219        // Loop over each transport on each HTTP request looking for one which will serve this request's needs
Note: See TracChangeset for help on using the changeset viewer.