html - How do i make an embedded youtube video shrink with the page when I have a nav bar being floated left, and a nav bar being floated right -


i making page on site in have put nav bar(float: right) , nav bar(float:left), whenever try embed youtube video, right nav bar ends @ bottom of page. know css code can use fix problem? have: html:

<div class="video-wrapper">  <iframe width="700" height="525" src="http://www.youtube.com/embed/myn5abpmpze?rel=0"     frameborder="0" allowfullscreen></iframe> </div> 

css:

    .videowrapper { position: relative; padding-bottom: 56.25%; /* 16:9 */ padding-top: 25px; height: 0; } .videowrapper iframe { position: absolute; top: 0; left: 0; width: 100%; height: 100%; } 

james first , foremost, question little ambiguous, since stated nav bar {float:left} , same nav bar floated again right. assuming different nav bars. if same there problem concept.

check code, css code has class named videowrapper assigned video-wrapper youtube video iframe. since, video-wrapper not defined in css file, browser renders in default flowlayout. try changing the class name make them consistent.


Comments

Popular posts from this blog

java - JavaFX 2 slider labelFormatter not being used -

Detect support for Shoutcast ICY MP3 without navigator.userAgent in Firefox? -

web - SVG not rendering properly in Firefox -