12% off of LTD using this coupon: TWELVEPERCENTOFF. Promo ends on 2 Dec midnight UTC.
Published on Dec 4, 2023

Post-specific Video Backgrounds in Oxygen using Meta Box

Sridhar Katakam

This Premium tutorial is similar to the Video Background in Oxygen using ACF tutorial, but when using Meta Box.

Step 1

Install and activate Meta Box and Meta Box AIO plugins.

Create this field group (JSON export) using Meta Box for your desired post type:

For the Video type field, set "Max number of files" to 1.

In the Settings tab, set the Location to your desired post type.

Step 2

Edit your Pages and populate the field for each.

Step 3

Let's create a function for use with a Dynamic Data condition to ensure that the video Section gets output only on Pages that have the field populated.

Install and activate a code snippets plugin like WPCodeBox 2.

Create a new PHP snippet.

Title: Check if the given Meta Box group is empty

Code:

This is a premium members-only content.

To view the rest of the content, please sign up for membership ($47/month or $599 one-time).

Already a member? Log in below or here.

tagschevron-leftchevron-rightchainangle-rightangle-upangle-downfolder-omagnifiercrossmenuchevron-downarrow-right