Can you add a background image in html?
This question already has an answer here:
删除双引号,然后像这样使用单引号
"background: url('../../img/followers/followers-tabs.png')
background-image:url('image path');
put this block of code in ur css and get the background image set.
You need to remove qoutes from the url
<div class="container" style="background: url(../../img/followers/followers-tabs.png) no-repeat 0 0px;"></div>
You could use '
but url
in CSS background doesn't need them at all.
Here's the fixed fiddle: http://jsfiddle.net/7Gacp/10/.
To spread the background you can use
background-size: 100% 100%;
Here's another fiddle: http://jsfiddle.net/7Gacp/11/.
链接地址: http://www.djcxy.com/p/89218.html上一篇: 图像不会100%向右
下一篇: 你可以在html中添加背景图片吗?