L.Adlon Posted June 24, 2014 Share Posted June 24, 2014 (edited) Hi. I'm using the W3Schools suggested YouTube <iframe> embedding method, and it works great in Firefox, but when viewed in Internet Explorer, it seems the video is about 2 pixels smaller horizontally and vertically, resulting in a thin padding on the bottom and right of the video (between it and the <div> frame. Anyone have any idea what might be happening here? The <div> frame seems to be the same size between the Firefox and IE version, and it's the video itself that has the size difference. I have the following style applied to the <iframe> of the video: .reel { text-align:center; margin:20 auto; padding:0px; border-style:double; border-width:6px; line-height:0px;} From what I see (and understand) there isn't anything there that should be affecting the video size or the padding (aside from making the padding zero). Also, it SEEMS that the white padding is in the video block itself, as opposed to in the padding area between the video element and the <div> frame surrounding it, as changing the background-color of the <iframe> does not change the color of the white padding. Any theories and/or suggestions? Edited June 24, 2014 by L.Adlon Link to comment Share on other sites More sharing options...
dsonesuk Posted June 24, 2014 Share Posted June 24, 2014 IE or youtube adds 8px margin on right and bottom edge for some reason. Link to comment Share on other sites More sharing options...
L.Adlon Posted June 24, 2014 Author Share Posted June 24, 2014 Oh, so it's a known/common thing, then? Do website guys do anything to remove that, or do they just shrug it off and leave it? Definitely looks like it's part of the video itself, and not the padding of the element. Put side by side, the video viewed in IE is a few pixels smaller than one in Firefox. Link to comment Share on other sites More sharing options...
dsonesuk Posted June 24, 2014 Share Posted June 24, 2014 its the youtube page it is in, so you can't access that to set margin: 0;, if you use embed tag to show movie, you don't have this problem. Link to comment Share on other sites More sharing options...
L.Adlon Posted June 24, 2014 Author Share Posted June 24, 2014 But is the embed tag currently fully supported by all (major) platforms and browsers, or is there still the need for the <object><embed> combo? Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now