Struggling here … How do I center align a shortcode element?
I have a shortcode that contains a Vimeo embed iframe. I want this to appear centered on the page. I’ve tried putting it in sections, blocks, divs and containers in a variety of combinations, then setting the flex align or block align etc. But it always puts the video player left aligned.
If I use the Video element then that aligns as I want, but sadly does not allow me to add a Do Not Track option, hence trying the embed code.
Thanks, but sadly not. Tried it on all the elements, nothing. I can move the iframe around by using specific margins or padding but thats not ideal. I just thought the flex align center would work.
I assume this is because it is an embeded iframe so the elements end size isn’t known, even though I have the size in the code.
Try this:
put short code inside rich text element in ‘text’ view, go to style tab typography and set text-align to center.
Doing the same in a short code element might work too.