Spring Sale: Our new update is live! Save 30% on Pro and Pro Unlimited for a limited time.

Video

In this article, we're going to discuss the Video Element in the Pro Builders and Cornerstone. We're going to show you the two types of videos supported by this element and how to configure each.

  1. Video Embed Setup
  2. Video Player Setup
  3. Video Controls Setup
  4. Frame Settings
  5. Effects
  6. Customize
  7. Demo
  8. Summary

To add the Video Element, simply search for "video" on the Elements search on your Cornerstone or any builder in Pro (Content, Header, Global Block, Footer) and drag the Video element on the content pane.

Video Element

Once you've added the element, you'll see this on the settings pane:

Video Element

Under Setup, you'll see Embed and Player. Let's discuss Embed first.

Video Embed Setup

On the Embed setup, you'll see a field named Embed Code. Websites such as Youtube and Vimeo (just to name a few) allow you to display their videos to your website. So let's say you want to add this Video from Youtube on to your website, just click the Share button:

Video Element

Then click the Embed button on the modal:

Video Element

Copy the Embed code:

Video Element

Then paste that code to the Video Element's Embed Code field:

Video Element

You'll then see that the video has been added along with the designs and controls found on Youtube also.

Video Element

Note: Different websites have their own embed codes.

Video Player Setup

Now the second setup option is Player.

Video Element

Basically, instead of using an embed code from a video hosting website, you'll have to enter the URL of the actual video file. If you host your video files, whether it's in your website or on a CDN provider, this is the option you will choose.

You simply have to enter the URL of the file (e.g. example.com/videos/my-video.mp4) on the Sources field.

Video Element

Now you'll notice that inside the parenthesis of the Sources field, there's a text that says "1 Per Line." Let me explain that. Because there are so many devices and browsers that could be viewing your website, and would want to watch your video, it is recommended that you offer multiple file sources. Basically, a source is the same video file offered in a different file format. So if you have an MP4 file format, it is recommended that you put an OGG, MOV and WEBM version as well.

The purpose is that if a certain browser doesn't play one video format (e.g. MP4), you'll have a backup format which the browser may support.

Here's how you will implement it:

Video Element

Lastly, there's the Poster field.

Video Element

This is the image that will display before the video is played. This is optional.

Video Controls Setup

If you select the Player setup, an additional set of options are added that allows you to customize the video player controls. They are the following:

Controls Setup

There's a dropdown labeled Preload Content with three options:

Video Element
  • None - Requests the browser not preload the video file.
  • Auto - Requests that the browser download the video file's metadata immediately on page load.
  • Metadata - Requests the browser to download the entire video file, regardless of whether the user is going to play it or not.

Note: There's no 100% guarantee that the browser will follow this. Some browsers ignore this option. You'll also see the

Display & Function option with five checkboxes:

Video Element
  • No Controls - If you check this option, the entire control bar will not be displayed. Users can still play and pause the video by clicking on the video itself. ** **
  • Advanced - If checked, the time, volume and full-screen controls will be displayed.
  • Autoplay - When checked, the video file will play automatically once the page is loaded.
  • Loop - If checked, the video file will replay after it is finished.
  • Muted - If checked, the video will play but there will be no sound.

Controls Colors

The controls colors control group gives you the ability to fine tune the color of various parts of the video control:

  • Buttons - Use this option to set the color of the play/paus button in the normal and hover mode.
  • Time Progress - Use this option to set the total progress bar color and the loaded portion.
  • Time Current - Use this option to set the elapsed time marker color in the progress bar.
  • Text - Use this option to set the text color of the control.
  • Background - use this option to set the background color of the control.
Video Element

Controls Margin

Use this option to set the margin of the control. You can change the settings for all the sides of the control or modify them individually.

Video Element

Controls Padding

Use this option to set the padding of the control. You can change the settings for all the sides of the control or modify them individually.

Video Element

Controls Border

Use this option to set the border of the control. You can set the style, width and color of the border on all sides or each side individually.

Video Element

Controls Border Radius

Use this option to set a border radius for the control. You can set the curve on all sides or set them individually.

Video Element

Controls Box Shadow

You can set a shadow over the control using the box-shadow control group.

  • X-Offset - Use this option to set the X offset of the shadow in the control.
  • Y-Offset - Use this option to set the Y offset of the shadow in the control.
  • Blur - Use this option to set the intensity of the blur effect in the control.
  • Spread & Position - Use this option to set the spread amount of the items section shadow and decide if you want the shadow to sit inside or outside of the control.
  • Color - Use this option to set the color of the control shadow.
Video Element

Time Rail Border Radius

Use this option to set a border radius for the time rail. You can set the curve on all sides or set them individually.

Video Element

Time Rail Box Shadow

You can set a shadow over the time rail using the box-shadow control group.

  • X-Offset - Use this option to set the X offset of the shadow in the time rail.
  • Y-Offset - Use this option to set the Y offset of the shadow in the time rail.
  • Blur - Use this option to set the intensity of the blur effect in the time rail.
  • Spread & Position - Use this option to set the spread amount of the items section shadow and decide if you want the shadow to sit inside or outside of the time rail.
  • Color - Use this option to set the color of the time rail shadow.
Video Element

Frame Settings

Not only can you configure how the player controls will look like, you can also configure how the video's frame looks like. Regardless of whether you chose an Embed or Player Video Type, you may configure the Frame's settings. To do that, click on the Frame tab.

Video Element

Setup

Video Element
  • Content Sizing- You can choose either Aspect Ratio or Fixed Height. If you choose Aspect Ratio, you can enter the ratio of the video's frame's width and height with respect to each other. If you choose Fixed Height, as the name suggests, the height of the frame is going to be "fixed." The width will be set by whatever value you enter on the Width & Max Width field.
  • Width & Max Width - Width is going to be the actual width of the frame and max width is its limit.
  • Background Color - Sometimes the video doesn't cover the entire frame such as if you add frame padding. You may choose to set a background color so that the background is not white.

Frame Margin

Use this option to set the margin of the frame. You can change the settings for all the sides of the frame or modify them individually.

Video Element

Frame Padding

Use this option to set the padding of the frame. You can change the settings for all the sides of the frame or modify them individually.

Video Element

Frame Border

Use this option to set the border of the frame. You can set the style, width and color of the border on all sides or each side individually.

Video Element

Frame Border Radius

Use this option to set a border radius for the frame. You can set the curve on all sides or set them individually.

Video Element

Frame Box Shadow

You can set a shadow over the frame using the box-shadow control group.

  • X-Offset - Use this option to set the X offset of the shadow in the frame.
  • Y-Offset - Use this option to set the Y offset of the shadow in the frame.
  • Blur - Use this option to set the intensity of the blur effect in the frame.
  • Spread & Position - Use this option to set the spread amount of the items section shadow and decide if you want the shadow to sit inside or outside of the frame.
  • Color - Use this option to set the color of the frame shadow.
Video Element

Effects

The Effects Module allows you to create stunning static and interactive changes to your Elements by leveraging CSS opacity, transform, filter, and much more. Click here for more detailed information.

Customize

  • ID - Use this option to set an HTML ID for the element. The ID should be unique on the page.
  • Class - Use this option to set an HTML Class for the element. You can use the class for your custom CSS code.
  • Element CSS - Use this option to have better control over the element to access the inner tags of the element using $el as the CSS selection. Click here for more detailed information.
  • Hide During Breakpoint - Use this option to hide the element on different device sizes. Click here for more information.
  • Conditions - Use this picker to display an Element only if it meets a certain condition (e.g. "post has featured image," "user is logged in," "post type is product," et cetera). Click here for more information.
  • Custom Attributes - Use this option to add a custom attributes to the wrapper HTML tag of the element. Such as data-info=123. You can use the option to inject custom information into the element to use on your customization code.
  • Looper Providers & Consumers - Use these controls to access information in your WordPress installation and output it on the frontend of your website using Elements from across our Builders. Click here for more information.

Demo

To see a live demo of the Video Element click here.

Summary

In this article, you learned how to add videos in Cornerstone or Pro Content builder. You learned the two video types namely "Embedded" and "Player." Lastly, you learned how to configure each type, giving you flexibility to set up your videos.

See something inaccurate? Let us know