How to fit a video to fill 100% of its div
Hello,
I have a video saved on my desktop that I would like to have fit responsivly in a div, although it does fit 100% of its width, it leaves a space top and bottom and shrinks as I scale the window down.
this is the code Im using..
<div class="electroststicTechnology">
<video autoplay loop muted width="100%" height="100%">
<source src="Video/Electrostatic_Technology.mp4" type="video/mp4"/>
<source src="Electrostatic_Technology.ogg" type="video/ogg"/>
</video>
</div>
CSS
.electroststicTechnologyPreview {
width: 40%;
height: 500px;
float: left;
position: relative;
overflow: hidden;
margin-right: auto;
margin-left: auto;
}
Thanks for your support !
