• Resolved pauloryn


    Is there a way to set the size of the video when using the shortcode? As you would in an iframe embed from youtube/vimeo?

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Alec Rust


    Hi @pauloryn thanks for your query.

    Protected Video uses the Plyr player which is responsive by default. The size of the player is determined by the aspect ratio of the video. In the same way Plyr doesn’t take width/height dimensions, I don’t think it’s really the place for Protected Video to either.

    Assuming you are using the “Shortcode Block” to embed the video, you can wrap the Shortcode with some HTML that includes CSS for restricting the width and centre aligning the video. For example:

    <div style="max-width: 400px; margin-left: auto; margin-right: auto;">
      [protected_video url="https://youtu.be/E03ILLUNYFc" service="youtube"]

    Does that work for your use case?

    Thread Starter pauloryn


    Hi Alex,

    Thanks that’s perfect for my needs.
    Much appreciated.

    Plugin Author Alec Rust


    Great to hear! I’ll mark this topic as resolved then.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘video size on page’ is closed to new replies.