Add video meta box to worpress posts
In this page we will see how we can add video meta box to worpress posts and pages. This page is actually about a plugin Video metabox that enables users to upload videos to wordpress media library. Once a video is uploaded, it can be displayed using any of following methods
Using php script
The script given below will output url of uploaded video.
1 | <?php echo aoc_get_post_video( $post_id )?> |
Using shortcode
In addition to above php script, you can also use this shortcode to display the video
1 | [aoc_video_box] |
This shortcode accepts all the attributes accepted by HTML video tag.