HTMLSnippet responsive

0
I have this   <div style="border: 0px solid rgb(201, 0, 1); overflow: hidden; margin: 15px auto;max-width: 950px"> <iframe class="responsive-iframe" scrolling="no" src="https" style="border: 0px none; margin-left: -37px; height: 950px; margin-top: -350px; width: 1000px;"> </iframe> </div>   how I could make it responsive?  
asked
2 answers
2

Hi Ismael,

If u want to make an element responsive please use percentage(%) for the properties of height and width instead of px and also don't use -margins for a element instead use position or translate properties and also follow the CSS best practices.

 

I hope this helps. 

answered
0

This page on W3Schools has an example of the CSS you would need to use. You would need to remove your inline styles if you added these to your stylesheet.

https://www.w3schools.com/howto/howto_css_responsive_iframes.asp

Good luck and I hope this helps.

answered