WordPress at a glance
function is not described

WP_oEmbed::_add_provider_early() public WP 4.0.0

Adds an oEmbed provider.

The provider is added just-in-time when wp_oembed_add_provider() is called before the 'plugins_loaded' hook.

The just-in-time addition is for the benefit of the 'oembed_providers' filter.

{} It's a method of the class: WP_oEmbed{}

No Hooks.


Null. Nothing.


$result = WP_oEmbed::_add_provider_early( $format, $provider, $regex );
$format(string) (required)
Format of URL that this provider can handle. You can use asterisks as wildcards.
$provider(string) (required)
The URL to the oEmbed provider..
Whether the $format parameter is in a regex format.
Default: false


  • See: wp_oembed_add_provider()


Since 4.0.0 Introduced.

Code of WP_oEmbed::_add_provider_early() WP 5.6

public static function _add_provider_early( $format, $provider, $regex = false ) {
	if ( empty( self::$early_providers['add'] ) ) {
		self::$early_providers['add'] = array();

	self::$early_providers['add'][ $format ] = array( $provider, $regex );