How to make video with full height

一世执手 提交于 2020-01-04 15:27:45

问题


I need your help to make this video with full height. Although, the div size is around 50% and when i make my video fixed position, it works like full background video but i want to make it fit into my div with full height.

Have look what i want Here

You can check my video html code

 <div class="video">
   <div id="video-holder" style="width:100%; position: absolute; height: auto !important; max-height:100%;">
	<video id="video" style="width:100%; height:100%;">
		<source src="http://www.w3schools.com/html/movie.ogg" type="video/ogg">
            
	</video>
   </div>
</div>

回答1:


Have you tried the following CSS for the video tag?:

{
  width: auto;
  height: 100%;
  position: fixed;
}

Given the example you mention this seems to put the video to a 100% of the height. If this is not exactly what you need just give us some more detailed explanation.



来源:https://stackoverflow.com/questions/30612353/how-to-make-video-with-full-height

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!