Enqueue the wp-embed script if the provided oEmbed HTML contains a post embed.
Description
In order to only enqueue the wp-embed script on pages that actually contain post embeds, this function checks if the provided HTML contains post embed markup and if so enqueues the script so that it will get printed in the footer.
Parameters
$htmlstring
Embed markup.
Return
string
Embed markup (without modifications).
Uses · 2
has_action()Checks if any action has been registered for a hook.
Signature, return type and hooks compared across 5 parsed releases.
About this page
Parsed data
Generated from the wordpress-develop 6.7.7 tag, from src/wp-includes/embed.php, and regenerated for each WordPress release so it tracks the code rather than a snapshot of it.
Corrections
Something wrong on this page? Report it and it gets fixed in the next regeneration.