WPDev.one
Core Function
View Source on Trac ↗

wp_embed_handler_youtube()

wp_embed_handler_youtube( mixed $matches, mixed $attr, mixed $url, mixed $rawattr )

YouTube iframe embed handler callback.

Parameters 4 required

Name / Type Description
array

$matches The RegEx matches from the provided regex when calling wp_embed_register_handler().

Required
$attr
array

Embed attributes.

Required
$url
string

The original URL that was matched by the regex.

Required
$rawattr
array

The original unmodified attributes.

Required

Return Value

(string)
The embed HTML.

Function Information

Since Version
4.0.0
Source File
wp-includes/embed.php
Advertisement