开发者

How to make icon to be displayed in the fixed place in my site?

I have fixed an icon in the place using jQuery

$('#edit').css({left:  512});

When i make the browser size small or big开发者_JAVA技巧 the icon is not on the same place. It's moving according to that current browser size.

How can it be controlled using jQuery to place icon in the same place even the browser size changes.


Why not using CSS instead of jQuery? Simply use fixed positioning.


In the css class put :

.logoClass { position : fixed; }


Try setting 'position :fixed;'

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜