开发者

CSS background tile beginning from the right edge

Are you aware of any mechanism to specify tiling of a background image so that it starts filling from top right corner, and开发者_如何学C not the default top left?

Width of the element in question is not fixed, of course.


Use background-position.

body
{
 background-image:url('http://www.schrijvenvoorinternet.nl/wp-content/banaan1.jpg');
 background-position: top right;   
}

Working example: http://jsfiddle.net/aVKzq/


#mydiv { background-position: right top; }

I am not sure if i understood your question correctly though.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜