WordPress at Your Fingertips
function is not described

WP_Embed::autoembed_callback() public WP 1.0

Callback function for WP_Embed::autoembed().

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

No Hooks.


String. The embed HTML on success, otherwise the original URL.


global $wp_embed;
$wp_embed->autoembed_callback( $match );
$match(array) (required)
A regex match array.

Code of WP_Embed::autoembed_callback() WP 5.8.2

public function autoembed_callback( $match ) {
	$oldval              = $this->linkifunknown;
	$this->linkifunknown = false;
	$return              = $this->shortcode( array(), $match[2] );
	$this->linkifunknown = $oldval;

	return $match[1] . $return . $match[3];