Switch language

wpseek.com
A WordPress-centric search engine for devs and theme authors




wp_oembed_add_provider [ WordPress Function ]

wp_oembed_add_provider ( $format, $provider, $regex = false )
Parameters:
  • (string) $format The format of URL that this provider can handle. You can use asterisks as wildcards.
  • (string) $provider The URL to the oEmbed provider.
  • (boolean) $regex Whether the $format parameter is in a regex format.
Uses:
See:
  • WP_oEmbed
Defined at:



Adds a URL format and oEmbed provider URL pair.

Source


<?php
function wp_oembed_add_provider$format$provider$regex false ) {
    require_once( 
ABSPATH WPINC '/class-oembed.php' );
    
$oembed _wp_oembed_get_object();
    
$oembed->providers[$format] = array( $provider$regex );
}
?>

Examples [ wp-snippets.com ]

Top Google zoekresultaten

Meer ...

0 User Note(s)

Nog geen één. Wees de eerste!

Nieuw toevoegen ...



HTML5 Powered with CSS3 / Styling, Performance & Integration, and Semantics