[wp-trac] [WordPress Trac] #36293: video/audio object passed to wp_video_shortcode/wp_audio_shortcode is always null
WordPress Trac
noreply at wordpress.org
Tue Mar 22 06:47:42 UTC 2016
#36293: video/audio object passed to wp_video_shortcode/wp_audio_shortcode is
always null
--------------------------+-----------------------------
Reporter: gnotaras | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: General | Version:
Severity: normal | Keywords:
Focuses: |
--------------------------+-----------------------------
Hi,
The following:
{{{
apply_filters( 'wp_video_shortcode', $output, $atts, $video, $post_id,
$library );
apply_filters( 'wp_audio_shortcode', $html, $atts, $audio, $post_id,
$library );
}}}
send the {{{$video}}} and {{{$audio}}} objects respectively to the
filtering function.
However, these objects seem to be always {{{null}}}.
By checking the relevant code I notice that these objects are only set
when the {{{$primary}}} variable is set to {{{false}}}. The code does not
clarify why the audio/video object is bound to that variable. Perhaps
someone more familiar with the logic behind these functions should check
this please.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/36293>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list