Opened 3 years ago
Closed 3 years ago
#59769 closed defect (bug) (wontfix)
Blocked preview of non built in media shortcodes
| Reported by: | programmin | Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | |
| Component: | Shortcodes | Version: | 6.3.2 |
| Severity: | normal | Keywords: | |
| Cc: | Focuses: |
Description
If I want to add my own display shortcode preview, this no longer works:
wp_ajax_parse_media_shortcode() now has:
<?php // Only process previews for media related shortcodes: $found_shortcodes = get_shortcode_tags_in_content( $shortcode ); $media_shortcodes = array( 'audio', 'embed', 'playlist', 'video', 'gallery', ); $other_shortcodes = array_diff( $found_shortcodes, $media_shortcodes ); if ( ! empty( $other_shortcodes ) ) { wp_send_json_error(); }
Change History (3)
#3
@
3 years ago
- Milestone Awaiting Review
- Resolution → wontfix
- Status new → closed
It is not intended for the wp_ajax_parse_media_shortcode function to provide previews of shortcodes except those provided by core. Any plugin that would like to provide a preview should do so through custom code that can account for who, when, and what previews are provided.
Note:
See TracTickets
for help on using tickets.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
This error actually started with WordPress 6.2.3 auto upgrade - which doesn't seem to have an option to choose in the version dropdown here in Trac.