ryan.od Posted May 22, 2008 Share Posted May 22, 2008 I'm trying to position a YouTube video in IE6, but I cannot get it to respond to margins or padding. You can see the issue here: http://www.hiddenexpedition.com/everest-trailer.html (remember, you need to be using IE6) Any thoughts? Thanks. RyanOD Quote Link to comment https://forums.phpfreaks.com/topic/106820-positioning-youtube-video-in-ie6/ Share on other sites More sharing options...
Xurion Posted May 23, 2008 Share Posted May 23, 2008 You could probably put a dvi around it and make it align centre. Quote Link to comment https://forums.phpfreaks.com/topic/106820-positioning-youtube-video-in-ie6/#findComment-548034 Share on other sites More sharing options...
haku Posted May 23, 2008 Share Posted May 23, 2008 The align tag is deprecated and as such shouldn't be used. To the OP - first, take off the left margin you have set. Next, give the div width that is the width of the video you want to show. Finally set the left and right margins to auto. So your CSS for the div should look like this: width: __px; //set this to the width of the youtube video margin: 0 auto; This *should* solve your problem, though it may not. I unfortunately don't have IE6 on my home setup, so I can't check it. As a side note, I don't say this to be harsh, but you should really buy a book on CSS. The CSS you are using is, well, its quite a mess. On top of this, you are using it inefficiently by putting it inline in your divs, and you are using some browser specific styles. If you pick up a book on CSS, you will find that problems like the one you have here are quite easy to deal with, and it will improve your site's loading times as well. Good luck! Quote Link to comment https://forums.phpfreaks.com/topic/106820-positioning-youtube-video-in-ie6/#findComment-548086 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.