WP_Embed::autoembed_callback( array $matches ): string
Callback function for WP_Embed::autoembed().
Parameters
-
$matches
array Required -
A regex match array.
Return
string The embed HTML on success, otherwise the original URL.
Source
File: wp-includes/class-wp-embed.php
.
View all references
public function autoembed_callback( $matches ) {
$oldval = $this->linkifunknown;
$this->linkifunknown = false;
$return = $this->shortcode( array(), $matches[2] );
$this->linkifunknown = $oldval;
return $matches[1] . $return . $matches[3];
}