X Pro: Add Shortcode To Button

Good Day,

Is it possible to add a shortcode to the button element? We would like to use a video modal popup so when the button is clicked a video container pops up.

Kind Regards


No need to use a button with shortcode. We can use V2 element CONTENT AREA MODAL. You can style the toggle as you like then add the video inside MODAL CONTENT.

Hope this helps.

Hi @Lely,

Thank you for the quick response, that does solve the issue.

However, the modal does not appear to be responsive?

The standard embed code can be wrapped in a


.video-responsive iframe{

<iframe width="560" height="315" src="https://www.youtube.com/embed/video-code" frameborder="0" allow="accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>

The idea here would be to allow for a 90% (w & h) container to be shown across all devices.

480px & smaller the container seems to overflow as well.

Thank you for the great support as always.


Another option you can take is to use the lightbox shortcode that comes with X which also supports the Vimeo Lightbox Setup.

Please check this detailed guide:

If you are still not able to get it to work, please provide us with the URL of the site in question.

Thank you.

Hi @Jade,

Thank you for the suggestion, we will try that out as well :slight_smile:

You are most welcome. :slight_smile:

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.