• I have a YouTube iframe embed code within a <div> in a Custom HTML block. I changed the video size within the ifram to 560. The <dev> is flush left within the page’s main text column. I need to wrap text around this Custom HTML block and can’t figure out how to do it, despite cruising quite a number of Google searches and other forums. How do I wrap text around a Custom HTML block?

Viewing 2 replies - 1 through 2 (of 2 total)
  • Add a CSS class to the <div> that contains the YouTube iframe embed code. Then add the following CSS code:

    .my-class {
      float: left;
      margin-right: 20px; /* Adjust this value to modify the spacing between the block and the text */
    }

    This will cause the Custom HTML block to be positioned to the left of the main text column, with a margin on the right side of the block, allowing the text to wrap around it. You can easily adjust the margin value to achieve the desired spacing between the block and the text.

    Thread Starter com800

    (@com800)

    Faisal, That worked. Thanks. Another question about the same YouTube iframe embed in DIVs. What media query format would I use to make that particular iframe video responsive?

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Wrap text around Custom HTML block’ is closed to new replies.