开发者

Center the page around a div

I want to center a div in the document body in jquery.

I have a read more button that shows an extra div when yo开发者_运维知识库u click it, and i want the move the window position to be centered around this div.


Take a look at the ScrollTo plugin. If memory serves correctly, it scrolls using the scrollbars so you don't take a massive performance hit.


Try this:

CSS: Is it possible to get a div that is 100% height, less a top and bottom margin?

Center the page around a div

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜