zopim chatting service like div required
If you look at this site http://blog.zopim.com/, you will see on the bottom right side a chatting service. I actually don't want the chatting service. I just want the div to be up on the top of all the stuff present on my site, like this one is.
How can I accomplish this? If anyone has any samples please share, it would be 开发者_C百科quite helpful.
As Bryan told you, use position: fixed. There are a few particularities you have to know about the position fixed. You have to give you element a position relative to the browser window (use top, right, bottom or left). If you have other divs that are already in position fixed, you maybe gonna use the z-index. Check this:
html:
<div id="floating">hurra i amm floating</div>
css:
div#floating {
position: fixed;
bottom:0;
right:0;
width: 100px;
height: 100px;
background: pink;
}
精彩评论