html - Overlaying text on top of an object -


i have youtube video on website. know if there way lay out text on top of video give specific title.

also how same on left side of video? using bootstrap well.

you can use z-index or position in-order this.

<div class="container">  <iframe width="560" height="315" src="//www.youtube.com/embed/yxvoqjewqoq" frameborder="0" allowfullscreen></iframe>     <div class="my-text"> text</div>     </div> 

css

body {     background: #efefea }  .container {     width: 600px;      margin: 0 auto;      padding: 10px;     position: relative;  }  iframe {     marign: 0 auto;  }  .my-text {     position: absolute;     color: #fff;     padding: 10px 0px;     text-align: center;      font-size: 50px;      background: rgba(0,0,0, 0.5);     top: 20px;     left: 0;      right: 0; } 

http://jsfiddle.net/websiddu/dy4exbcp/1/


Comments

Popular posts from this blog

Python Kivy ListView: How to delete selected ListItemButton? -

asp.net mvc 4 - A specified Include path is not valid. The EntityType '' does not declare a navigation property with the name '' -