Fitting iframe inside a div

Hello guys,

this is the link
iframe doesn’t fit the div

I have an issue with an iframe map (not a google one…)

<iframe width="100%" height="100%" frameborder="0" scrolling="no" marginheight="0" marginwidth="0" style="border: 0"
 src="http://www.openstreetmap.org/export/embed.html?bbox=-84.39697265625%2C39.08743603215884%2C-69.89501953125%2C46.27863122156088&amp;layer=mapnik">
</iframe>

I would like to fit 100% inside a div that changes high responsively : from 400 px (desktop) to 300px (mobile).
I set the iframe height=100% but the map doesn’t fit the div high.
Please someone could help me to fix that?
Thank you.

Malek

Give the embed component a class, then set it to display block and height 100%.

Hello Samliew,

I’ve done what you said and… it works perfectly!
Yesterday I spent hours on google looking for a solution.

Thank you very much indeed.

Malek

You are welcome. I hope you are enjoying Webflow!

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