media_send_to_editor()
Adds image HTML to editor.
No Hooks.
Returns
null
. Nothing (null).
Usage
media_send_to_editor( $html );
- $html(string) (required)
- .
Changelog
Since 2.5.0 | Introduced. |
media_send_to_editor() media send to editor code WP 6.8.1
<?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; }