wp_http_accept_encoding WordPress Filter Hook

The wp_http_accept_encoding hook allows you to modify the list of encodings that are acceptable to WordPress. This can be useful if you want to add or remove an encoding from the list.

apply_filters( 'wp_http_accept_encoding', string[] $type, string $url, array $args ) #

Filters the allowed encoding types.


Parameters

$type

(string[])Array of what encoding types to accept and their priority values.

$url

(string)URL of the HTTP request.

$args

(array)HTTP request arguments.


Top ↑

More Information

Note that the filter function must return a $type value after it is finished processing or the HTTP call will fail.


Top ↑

Source

File: wp-includes/class-wp-http-encoding.php

View on Trac



Top ↑

Changelog

Changelog
VersionDescription
3.6.0Introduced.

The content displayed on this page has been created in part by processing WordPress source code files which are made available under the GPLv2 (or a later version) license by theĀ Free Software Foundation. In addition to this, the content includes user-written examples and information. All material is subject to review and curation by the WPPaste.com community.