oembed_fetch_url WordPress Filter Hook

The oembed_fetch_url Wordpress hook allows you to modify the URL that is fetched when using the oEmbed API. This can be useful if you want to change the URL of the oEmbed provider, or if you want to fetch the URL from a different source.

apply_filters( 'oembed_fetch_url', string $provider, string $url, array $args ) #

Filters the oEmbed URL to be fetched.


Parameters

$provider

(string)URL of the oEmbed provider.

$url

(string)URL of the content to be embedded.

$args

(array) Additional arguments for retrieving embed HTML. See wp_oembed_get() for accepted arguments. Default empty.


Top ↑

Source

File: wp-includes/class-wp-oembed.php

View on Trac



Top ↑

Changelog

Changelog
VersionDescription
4.9.0The dnt (Do Not Track) query parameter was added to all oEmbed provider URLs.
2.9.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.