Summery Summery
Prints the JavaScript in the embed iframe header.
Syntax Syntax
Source Source
File: wp-includes/embed.php
?>
</style>
<?php
}
/**
* Prints the JavaScript in the embed iframe header.
*
* @since 4.4.0
*/
function print_embed_scripts() {
$type_attr = current_theme_supports( 'html5', 'script' ) ? '' : ' type="text/javascript"';
?>
<script<?php echo $type_attr; ?>>
<?php
if ( SCRIPT_DEBUG ) {
readfile( ABSPATH . WPINC . '/js/wp-embed-template.js' );
} else {
/*
* If you're looking at a src version of this file, you'll see an "include"
* statement below. This is used by the `npm run build` process to directly
* include a minified version of wp-embed-template.js, instead of using the
* readfile() method from above.
*
* If you're looking at a build version of this file, you'll see a string of
* minified JavaScript. If you need to debug it, please turn on SCRIPT_DEBUG
* and edit wp-embed-template.js directly.
Advertisement
Changelog Changelog
| Version | Description |
|---|---|
| 4.4.0 | Introduced. |