WordPress at Your Fingertips
function is not described

media_send_to_editor() WP 2.5.0

Adds image HTML to editor.

No Hooks.

Return

null. Nothing.

Usage

media_send_to_editor( $html );
$html(string) (required)
-

Changelog

Since 2.5.0 Introduced.

Code of media_send_to_editor() WP 5.8.2

<?php
function media_send_to_editor( $html ) {
	?>
	<script type="text/javascript">
	var win = window.dialogArguments || opener || parent || top;
	win.send_to_editor( <?php echo wp_json_encode( $html ); ?> );
	</script>
	<?php
	exit;
}