http://codepen.io/basickarl/pen/Wrwdam?editors=110
html:
<div class="back">
</div>
css:
html,
body {
height: 100%;
}
div.back {
margin-top: 50px;
display: absolute;
width: 30px;
height: 30px;
background-image: url('http://simpleicon.com/wp-content/uploads/arrow-35.png');
background-repeat: no-repeat;
background-position: center;
background-size: contain;
}
The scrollbar on the right displays. I have to have html, body at 100% because of a sticky footer I'm using. Any ideas?
body { overflow:hidden; }
margin-top: 50px
, trypadding-top: 50px
margin:0;padding:0
to the html and body styles. Also you have an error in the CSSdisplay:absolute
is not a valid property/value (maybedisplay:block
orposition:absolute
but notdisplay:absolute
)