I am trying to put a background image behind my opening door css element and cannot for the life of me figure it out!
code located here http://codepen.io/anon/pen/ydAKz
had to include underneath code to post
script src="http://s.codepen.io/assets/libs/prefixfree.min.js"></script>
<script src="http://code.jquery.com/jquery-latest.js"></script>
<p class="alert"></p>
<div class="perspective" onclick="openDoor(this)">
<div class="thumb">
</div>
</div>
thanks in advance
try this code DEMO
body
{
/*background-color:#f0f0f0;*/
background: url(https://encrypted-tbn2.gstatic.com/images?q=tbn:ANd9GcR2BmZU1kR795PbCjY--wGWcdHvgdq4oM43UgpHSGKF6rk-qrhMiEFqGFe-) no-repeat;
width: 100%;
height: auto;
background-size: contain;
}
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.